/*
 *
 *    Copyright (c) 2021 Project CHIP Authors
 *
 *    Licensed under the Apache License, Version 2.0 (the "License");
 *    you may not use this file except in compliance with the License.
 *    You may obtain a copy of the License at
 *
 *        http://www.apache.org/licenses/LICENSE-2.0
 *
 *    Unless required by applicable law or agreed to in writing, software
 *    distributed under the License is distributed on an "AS IS" BASIS,
 *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *    See the License for the specific language governing permissions and
 *    limitations under the License.
 */

// THIS FILE IS GENERATED BY ZAP

#pragma once

#include "TestCommand.h"

class TV_TargetNavigatorCluster : public TestCommand
{
public:
    TV_TargetNavigatorCluster() : TestCommand("TV_TargetNavigatorCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_TargetNavigatorCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterTargetNavigatorCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterTargetNavigatorCommandNavigateTarget_1();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_TargetNavigatorCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 2;

    //
    // Tests methods
    //

    // Test Read attribute Target Navigator list
    using SuccessCallback_0 = void (*)(void * context, uint16_t count, _NavigateTargetTargetInfo * targetNavigatorList);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterTargetNavigatorCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterTargetNavigatorCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterTargetNavigatorCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Target Navigator - Read attribute Target Navigator list: Sending command...");

        chip::Controller::TargetNavigatorCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeTargetNavigatorList(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterTargetNavigatorCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Target Navigator - Read attribute Target Navigator list: Failure Response");

        TV_TargetNavigatorCluster * runner = reinterpret_cast<TV_TargetNavigatorCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void
    OnTestSendClusterTargetNavigatorCommandReadAttribute_0_SuccessResponse(void * context, uint16_t count,
                                                                           _NavigateTargetTargetInfo * targetNavigatorList)
    {
        ChipLogProgress(chipTool, "Target Navigator - Read attribute Target Navigator list: Success Response");

        TV_TargetNavigatorCluster * runner = reinterpret_cast<TV_TargetNavigatorCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 2)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "[object Object],[object Object]");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Navigate Target Command
    using SuccessCallback_1 = void (*)(void * context, uint8_t status, chip::ByteSpan data);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterTargetNavigatorCommandNavigateTarget_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterTargetNavigatorCommandNavigateTarget_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterTargetNavigatorCommandNavigateTarget_1()
    {
        ChipLogProgress(chipTool, "Target Navigator - Navigate Target Command: Sending command...");

        chip::Controller::TargetNavigatorCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t targetArgument      = 1;
        chip::ByteSpan dataArgument = chip::ByteSpan(chip::Uint8::from_const_char("1"), strlen("1"));
        err = cluster.NavigateTarget(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel(), targetArgument, dataArgument);

        return err;
    }

    static void OnTestSendClusterTargetNavigatorCommandNavigateTarget_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Target Navigator - Navigate Target Command: Failure Response");

        TV_TargetNavigatorCluster * runner = reinterpret_cast<TV_TargetNavigatorCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTargetNavigatorCommandNavigateTarget_1_SuccessResponse(void * context, uint8_t status,
                                                                                        chip::ByteSpan data)
    {
        ChipLogProgress(chipTool, "Target Navigator - Navigate Target Command: Success Response");

        TV_TargetNavigatorCluster * runner = reinterpret_cast<TV_TargetNavigatorCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_AudioOutputCluster : public TestCommand
{
public:
    TV_AudioOutputCluster() : TestCommand("TV_AudioOutputCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_AudioOutputCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterAudioOutputCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterAudioOutputCommandSelectOutput_1();
            break;
        case 2:
            err = TestSendClusterAudioOutputCommandRenameOutput_2();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_AudioOutputCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 3;

    //
    // Tests methods
    //

    // Test Read attribute Audio Output list
    using SuccessCallback_0 = void (*)(void * context, uint16_t count, _AudioOutputInfo * audioOutputList);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterAudioOutputCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterAudioOutputCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterAudioOutputCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Audio Output - Read attribute Audio Output list: Sending command...");

        chip::Controller::AudioOutputCluster cluster;
        cluster.Associate(mDevice, 2);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeAudioOutputList(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterAudioOutputCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Audio Output - Read attribute Audio Output list: Failure Response");

        TV_AudioOutputCluster * runner = reinterpret_cast<TV_AudioOutputCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterAudioOutputCommandReadAttribute_0_SuccessResponse(void * context, uint16_t count,
                                                                                   _AudioOutputInfo * audioOutputList)
    {
        ChipLogProgress(chipTool, "Audio Output - Read attribute Audio Output list: Success Response");

        TV_AudioOutputCluster * runner = reinterpret_cast<TV_AudioOutputCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 3)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "[object Object],[object Object],[object Object]");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Select Output Command
    using SuccessCallback_1 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterAudioOutputCommandSelectOutput_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterAudioOutputCommandSelectOutput_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterAudioOutputCommandSelectOutput_1()
    {
        ChipLogProgress(chipTool, "Audio Output - Select Output Command: Sending command...");

        chip::Controller::AudioOutputCluster cluster;
        cluster.Associate(mDevice, 2);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t indexArgument = 1;
        err                   = cluster.SelectOutput(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel(), indexArgument);

        return err;
    }

    static void OnTestSendClusterAudioOutputCommandSelectOutput_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Audio Output - Select Output Command: Failure Response");

        TV_AudioOutputCluster * runner = reinterpret_cast<TV_AudioOutputCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterAudioOutputCommandSelectOutput_1_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Audio Output - Select Output Command: Success Response");

        TV_AudioOutputCluster * runner = reinterpret_cast<TV_AudioOutputCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Rename Output Command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterAudioOutputCommandRenameOutput_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterAudioOutputCommandRenameOutput_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterAudioOutputCommandRenameOutput_2()
    {
        ChipLogProgress(chipTool, "Audio Output - Rename Output Command: Sending command...");

        chip::Controller::AudioOutputCluster cluster;
        cluster.Associate(mDevice, 2);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t indexArgument       = 1;
        chip::ByteSpan nameArgument = chip::ByteSpan(chip::Uint8::from_const_char("exampleName"), strlen("exampleName"));
        err = cluster.RenameOutput(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel(), indexArgument, nameArgument);

        return err;
    }

    static void OnTestSendClusterAudioOutputCommandRenameOutput_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Audio Output - Rename Output Command: Failure Response");

        TV_AudioOutputCluster * runner = reinterpret_cast<TV_AudioOutputCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterAudioOutputCommandRenameOutput_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Audio Output - Rename Output Command: Success Response");

        TV_AudioOutputCluster * runner = reinterpret_cast<TV_AudioOutputCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_ApplicationLauncherCluster : public TestCommand
{
public:
    TV_ApplicationLauncherCluster() : TestCommand("TV_ApplicationLauncherCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_ApplicationLauncherCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterApplicationLauncherCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterApplicationLauncherCommandLaunchApp_1();
            break;
        case 2:
            err = TestSendClusterApplicationLauncherCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterApplicationLauncherCommandReadAttribute_3();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_ApplicationLauncherCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 4;

    //
    // Tests methods
    //

    // Test Read attribute Application Launcher list
    using SuccessCallback_0 = void (*)(void * context, uint16_t count, uint16_t * applicationLauncherList);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterApplicationLauncherCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterApplicationLauncherCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterApplicationLauncherCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute Application Launcher list: Sending command...");

        chip::Controller::ApplicationLauncherCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeApplicationLauncherList(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationLauncherCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute Application Launcher list: Failure Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationLauncherCommandReadAttribute_0_SuccessResponse(void * context, uint16_t count,
                                                                                           uint16_t * applicationLauncherList)
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute Application Launcher list: Success Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 2)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "123,456");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Launch App Command
    using SuccessCallback_1 = void (*)(void * context, uint8_t status, chip::ByteSpan data);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterApplicationLauncherCommandLaunchApp_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterApplicationLauncherCommandLaunchApp_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterApplicationLauncherCommandLaunchApp_1()
    {
        ChipLogProgress(chipTool, "Application Launcher - Launch App Command: Sending command...");

        chip::Controller::ApplicationLauncherCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan dataArgument          = chip::ByteSpan(chip::Uint8::from_const_char("exampleData"), strlen("exampleData"));
        uint16_t catalogVendorIdArgument     = 1U;
        chip::ByteSpan applicationIdArgument = chip::ByteSpan(chip::Uint8::from_const_char("appId"), strlen("appId"));
        err = cluster.LaunchApp(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel(), dataArgument, catalogVendorIdArgument,
                                applicationIdArgument);

        return err;
    }

    static void OnTestSendClusterApplicationLauncherCommandLaunchApp_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Launcher - Launch App Command: Failure Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationLauncherCommandLaunchApp_1_SuccessResponse(void * context, uint8_t status,
                                                                                       chip::ByteSpan data)
    {
        ChipLogProgress(chipTool, "Application Launcher - Launch App Command: Success Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute catalog vendor id
    using SuccessCallback_2 = void (*)(void * context, uint8_t catalogVendorId);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterApplicationLauncherCommandReadAttribute_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterApplicationLauncherCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterApplicationLauncherCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute catalog vendor id: Sending command...");

        chip::Controller::ApplicationLauncherCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCatalogVendorId(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationLauncherCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute catalog vendor id: Failure Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationLauncherCommandReadAttribute_2_SuccessResponse(void * context, uint8_t catalogVendorId)
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute catalog vendor id: Success Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (catalogVendorId != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute application id
    using SuccessCallback_3 = void (*)(void * context, uint8_t applicationId);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterApplicationLauncherCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterApplicationLauncherCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterApplicationLauncherCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute application id: Sending command...");

        chip::Controller::ApplicationLauncherCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeApplicationId(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationLauncherCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute application id: Failure Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationLauncherCommandReadAttribute_3_SuccessResponse(void * context, uint8_t applicationId)
    {
        ChipLogProgress(chipTool, "Application Launcher - Read attribute application id: Success Response");

        TV_ApplicationLauncherCluster * runner = reinterpret_cast<TV_ApplicationLauncherCluster *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (applicationId != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_KeypadInputCluster : public TestCommand
{
public:
    TV_KeypadInputCluster() : TestCommand("TV_KeypadInputCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_KeypadInputCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterKeypadInputCommandSendKey_0();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_KeypadInputCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 1;

    //
    // Tests methods
    //

    // Test Send Key Command
    using SuccessCallback_0 = void (*)(void * context, uint8_t status);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterKeypadInputCommandSendKey_0_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterKeypadInputCommandSendKey_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterKeypadInputCommandSendKey_0()
    {
        ChipLogProgress(chipTool, "Keypad Input - Send Key Command: Sending command...");

        chip::Controller::KeypadInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t keyCodeArgument = 3;
        err                     = cluster.SendKey(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel(), keyCodeArgument);

        return err;
    }

    static void OnTestSendClusterKeypadInputCommandSendKey_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Keypad Input - Send Key Command: Failure Response");

        TV_KeypadInputCluster * runner = reinterpret_cast<TV_KeypadInputCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterKeypadInputCommandSendKey_0_SuccessResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Keypad Input - Send Key Command: Success Response");

        TV_KeypadInputCluster * runner = reinterpret_cast<TV_KeypadInputCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_AccountLoginCluster : public TestCommand
{
public:
    TV_AccountLoginCluster() : TestCommand("TV_AccountLoginCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_AccountLoginCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterAccountLoginCommandGetSetupPIN_0();
            break;
        case 1:
            err = TestSendClusterAccountLoginCommandLogin_1();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_AccountLoginCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 2;

    //
    // Tests methods
    //

    // Test Get Setup PIN Command
    using SuccessCallback_0 = void (*)(void * context, chip::ByteSpan setupPIN);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterAccountLoginCommandGetSetupPIN_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterAccountLoginCommandGetSetupPIN_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterAccountLoginCommandGetSetupPIN_0()
    {
        ChipLogProgress(chipTool, "Account Login - Get Setup PIN Command: Sending command...");

        chip::Controller::AccountLoginCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan tempAccountIdentifierArgument = chip::ByteSpan(chip::Uint8::from_const_char("asdf"), strlen("asdf"));
        err = cluster.GetSetupPIN(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel(), tempAccountIdentifierArgument);

        return err;
    }

    static void OnTestSendClusterAccountLoginCommandGetSetupPIN_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Account Login - Get Setup PIN Command: Failure Response");

        TV_AccountLoginCluster * runner = reinterpret_cast<TV_AccountLoginCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterAccountLoginCommandGetSetupPIN_0_SuccessResponse(void * context, chip::ByteSpan setupPIN)
    {
        ChipLogProgress(chipTool, "Account Login - Get Setup PIN Command: Success Response");

        TV_AccountLoginCluster * runner = reinterpret_cast<TV_AccountLoginCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Login Command
    using SuccessCallback_1 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterAccountLoginCommandLogin_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterAccountLoginCommandLogin_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterAccountLoginCommandLogin_1()
    {
        ChipLogProgress(chipTool, "Account Login - Login Command: Sending command...");

        chip::Controller::AccountLoginCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan tempAccountIdentifierArgument = chip::ByteSpan(chip::Uint8::from_const_char("asdf"), strlen("asdf"));
        chip::ByteSpan setupPINArgument = chip::ByteSpan(chip::Uint8::from_const_char("tempPin123"), strlen("tempPin123"));
        err = cluster.Login(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel(), tempAccountIdentifierArgument,
                            setupPINArgument);

        return err;
    }

    static void OnTestSendClusterAccountLoginCommandLogin_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Account Login - Login Command: Failure Response");

        TV_AccountLoginCluster * runner = reinterpret_cast<TV_AccountLoginCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterAccountLoginCommandLogin_1_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Account Login - Login Command: Success Response");

        TV_AccountLoginCluster * runner = reinterpret_cast<TV_AccountLoginCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_ApplicationBasicCluster : public TestCommand
{
public:
    TV_ApplicationBasicCluster() : TestCommand("TV_ApplicationBasicCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_ApplicationBasicCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterApplicationBasicCommandChangeStatus_0();
            break;
        case 1:
            err = TestSendClusterApplicationBasicCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterApplicationBasicCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterApplicationBasicCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterApplicationBasicCommandReadAttribute_4();
            break;
        case 5:
            err = TestSendClusterApplicationBasicCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterApplicationBasicCommandReadAttribute_6();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_ApplicationBasicCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 7;

    //
    // Tests methods
    //

    // Test Change Status Command
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterApplicationBasicCommandChangeStatus_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterApplicationBasicCommandChangeStatus_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandChangeStatus_0()
    {
        ChipLogProgress(chipTool, "Application Basic - Change Status Command: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t statusArgument = 1;
        err                    = cluster.ChangeStatus(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel(), statusArgument);

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandChangeStatus_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Change Status Command: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandChangeStatus_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Application Basic - Change Status Command: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute vendor name
    using SuccessCallback_1 = void (*)(void * context, chip::ByteSpan vendorName);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterApplicationBasicCommandReadAttribute_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterApplicationBasicCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute vendor name: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeVendorName(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute vendor name: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_1_SuccessResponse(void * context, chip::ByteSpan vendorName)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute vendor name: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute vendor id
    using SuccessCallback_2 = void (*)(void * context, uint16_t vendorId);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterApplicationBasicCommandReadAttribute_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterApplicationBasicCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute vendor id: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeVendorId(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute vendor id: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_2_SuccessResponse(void * context, uint16_t vendorId)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute vendor id: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (vendorId != 1U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute name
    using SuccessCallback_3 = void (*)(void * context, chip::ByteSpan applicationName);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterApplicationBasicCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterApplicationBasicCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute name: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeApplicationName(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute name: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_3_SuccessResponse(void * context,
                                                                                        chip::ByteSpan applicationName)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute name: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute product id
    using SuccessCallback_4 = void (*)(void * context, uint16_t productId);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterApplicationBasicCommandReadAttribute_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterApplicationBasicCommandReadAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandReadAttribute_4()
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute product id: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeProductId(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute product id: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_4_SuccessResponse(void * context, uint16_t productId)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute product id: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (productId != 1U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute id
    using SuccessCallback_5 = void (*)(void * context, chip::ByteSpan applicationId);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterApplicationBasicCommandReadAttribute_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterApplicationBasicCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute id: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeApplicationId(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute id: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_5_SuccessResponse(void * context,
                                                                                        chip::ByteSpan applicationId)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute id: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute catalog vendor id
    using SuccessCallback_6 = void (*)(void * context, uint16_t catalogVendorId);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterApplicationBasicCommandReadAttribute_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterApplicationBasicCommandReadAttribute_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterApplicationBasicCommandReadAttribute_6()
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute catalog vendor id: Sending command...");

        chip::Controller::ApplicationBasicCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCatalogVendorId(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel());

        return err;
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute catalog vendor id: Failure Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterApplicationBasicCommandReadAttribute_6_SuccessResponse(void * context, uint16_t catalogVendorId)
    {
        ChipLogProgress(chipTool, "Application Basic - Read attribute catalog vendor id: Success Response");

        TV_ApplicationBasicCluster * runner = reinterpret_cast<TV_ApplicationBasicCluster *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (catalogVendorId != 1U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_MediaPlaybackCluster : public TestCommand
{
public:
    TV_MediaPlaybackCluster() : TestCommand("TV_MediaPlaybackCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_MediaPlaybackCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterMediaPlaybackCommandMediaPlay_0();
            break;
        case 1:
            err = TestSendClusterMediaPlaybackCommandMediaPause_1();
            break;
        case 2:
            err = TestSendClusterMediaPlaybackCommandMediaStop_2();
            break;
        case 3:
            err = TestSendClusterMediaPlaybackCommandMediaStartOver_3();
            break;
        case 4:
            err = TestSendClusterMediaPlaybackCommandMediaPrevious_4();
            break;
        case 5:
            err = TestSendClusterMediaPlaybackCommandMediaNext_5();
            break;
        case 6:
            err = TestSendClusterMediaPlaybackCommandMediaRewind_6();
            break;
        case 7:
            err = TestSendClusterMediaPlaybackCommandMediaFastForward_7();
            break;
        case 8:
            err = TestSendClusterMediaPlaybackCommandMediaSkipForward_8();
            break;
        case 9:
            err = TestSendClusterMediaPlaybackCommandMediaSkipBackward_9();
            break;
        case 10:
            err = TestSendClusterMediaPlaybackCommandMediaSeek_10();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_MediaPlaybackCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 11;

    //
    // Tests methods
    //

    // Test Media Playback Play Command
    using SuccessCallback_0 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterMediaPlaybackCommandMediaPlay_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterMediaPlaybackCommandMediaPlay_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaPlay_0()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Play Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaPlay(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaPlay_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Play Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaPlay_0_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Play Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Pause Command
    using SuccessCallback_1 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterMediaPlaybackCommandMediaPause_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterMediaPlaybackCommandMediaPause_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaPause_1()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Pause Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaPause(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaPause_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Pause Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaPause_1_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Pause Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Stop Command
    using SuccessCallback_2 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterMediaPlaybackCommandMediaStop_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterMediaPlaybackCommandMediaStop_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaStop_2()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Stop Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaStop(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaStop_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Stop Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaStop_2_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Stop Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Start Over Command
    using SuccessCallback_3 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterMediaPlaybackCommandMediaStartOver_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterMediaPlaybackCommandMediaStartOver_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaStartOver_3()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Start Over Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaStartOver(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaStartOver_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Start Over Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaStartOver_3_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Start Over Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Previous Command
    using SuccessCallback_4 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterMediaPlaybackCommandMediaPrevious_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterMediaPlaybackCommandMediaPrevious_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaPrevious_4()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Previous Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaPrevious(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaPrevious_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Previous Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaPrevious_4_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Previous Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Next Command
    using SuccessCallback_5 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterMediaPlaybackCommandMediaNext_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterMediaPlaybackCommandMediaNext_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaNext_5()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Next Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaNext(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaNext_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Next Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaNext_5_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Next Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Rewind Command
    using SuccessCallback_6 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterMediaPlaybackCommandMediaRewind_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterMediaPlaybackCommandMediaRewind_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaRewind_6()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Rewind Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaRewind(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaRewind_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Rewind Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaRewind_6_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Rewind Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Fast Forward Command
    using SuccessCallback_7 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterMediaPlaybackCommandMediaFastForward_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterMediaPlaybackCommandMediaFastForward_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaFastForward_7()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Fast Forward Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.MediaFastForward(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaFastForward_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Fast Forward Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaFastForward_7_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Fast Forward Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Skip Forward Command
    using SuccessCallback_8 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterMediaPlaybackCommandMediaSkipForward_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterMediaPlaybackCommandMediaSkipForward_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaSkipForward_8()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Skip Forward Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t deltaPositionMillisecondsArgument = 100ULL;
        err = cluster.MediaSkipForward(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel(),
                                       deltaPositionMillisecondsArgument);

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaSkipForward_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Skip Forward Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaSkipForward_8_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Skip Forward Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Skip Backward Command
    using SuccessCallback_9 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterMediaPlaybackCommandMediaSkipBackward_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterMediaPlaybackCommandMediaSkipBackward_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaSkipBackward_9()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Skip Backward Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t deltaPositionMillisecondsArgument = 100ULL;
        err = cluster.MediaSkipBackward(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel(),
                                        deltaPositionMillisecondsArgument);

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaSkipBackward_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Skip Backward Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaSkipBackward_9_SuccessResponse(void * context,
                                                                                         uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Skip Backward Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Media Playback Seek Command
    using SuccessCallback_10 = void (*)(void * context, uint8_t mediaPlaybackStatus);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterMediaPlaybackCommandMediaSeek_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterMediaPlaybackCommandMediaSeek_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterMediaPlaybackCommandMediaSeek_10()
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Seek Command: Sending command...");

        chip::Controller::MediaPlaybackCluster cluster;
        cluster.Associate(mDevice, 3);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t positionArgument = 100ULL;
        err = cluster.MediaSeek(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel(), positionArgument);

        return err;
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaSeek_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Seek Command: Failure Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaPlaybackCommandMediaSeek_10_SuccessResponse(void * context, uint8_t mediaPlaybackStatus)
    {
        ChipLogProgress(chipTool, "Media Playback - Media Playback Seek Command: Success Response");

        TV_MediaPlaybackCluster * runner = reinterpret_cast<TV_MediaPlaybackCluster *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mediaPlaybackStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_TvChannelCluster : public TestCommand
{
public:
    TV_TvChannelCluster() : TestCommand("TV_TvChannelCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_TvChannelCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterTvChannelCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterTvChannelCommandChangeChannelByNumber_1();
            break;
        case 2:
            err = TestSendClusterTvChannelCommandSkipChannel_2();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_TvChannelCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 3;

    //
    // Tests methods
    //

    // Test Read attribute TV Channel list
    using SuccessCallback_0 = void (*)(void * context, uint16_t count, _TvChannelInfo * tvChannelList);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterTvChannelCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterTvChannelCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterTvChannelCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "TV Channel - Read attribute TV Channel list: Sending command...");

        chip::Controller::TvChannelCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeTvChannelList(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterTvChannelCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "TV Channel - Read attribute TV Channel list: Failure Response");

        TV_TvChannelCluster * runner = reinterpret_cast<TV_TvChannelCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTvChannelCommandReadAttribute_0_SuccessResponse(void * context, uint16_t count,
                                                                                 _TvChannelInfo * tvChannelList)
    {
        ChipLogProgress(chipTool, "TV Channel - Read attribute TV Channel list: Success Response");

        TV_TvChannelCluster * runner = reinterpret_cast<TV_TvChannelCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 2)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "[object Object],[object Object]");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Change Channel By Number Command
    using SuccessCallback_1 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterTvChannelCommandChangeChannelByNumber_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterTvChannelCommandChangeChannelByNumber_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterTvChannelCommandChangeChannelByNumber_1()
    {
        ChipLogProgress(chipTool, "TV Channel - Change Channel By Number Command: Sending command...");

        chip::Controller::TvChannelCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t majorNumberArgument = 1U;
        uint16_t minorNumberArgument = 2U;
        err = cluster.ChangeChannelByNumber(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel(), majorNumberArgument,
                                            minorNumberArgument);

        return err;
    }

    static void OnTestSendClusterTvChannelCommandChangeChannelByNumber_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "TV Channel - Change Channel By Number Command: Failure Response");

        TV_TvChannelCluster * runner = reinterpret_cast<TV_TvChannelCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTvChannelCommandChangeChannelByNumber_1_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "TV Channel - Change Channel By Number Command: Success Response");

        TV_TvChannelCluster * runner = reinterpret_cast<TV_TvChannelCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Skip Channel Command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterTvChannelCommandSkipChannel_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterTvChannelCommandSkipChannel_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterTvChannelCommandSkipChannel_2()
    {
        ChipLogProgress(chipTool, "TV Channel - Skip Channel Command: Sending command...");

        chip::Controller::TvChannelCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t countArgument = 1U;
        err                    = cluster.SkipChannel(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel(), countArgument);

        return err;
    }

    static void OnTestSendClusterTvChannelCommandSkipChannel_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "TV Channel - Skip Channel Command: Failure Response");

        TV_TvChannelCluster * runner = reinterpret_cast<TV_TvChannelCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTvChannelCommandSkipChannel_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "TV Channel - Skip Channel Command: Success Response");

        TV_TvChannelCluster * runner = reinterpret_cast<TV_TvChannelCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_LowPowerCluster : public TestCommand
{
public:
    TV_LowPowerCluster() : TestCommand("TV_LowPowerCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_LowPowerCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterLowPowerCommandSleep_0();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_LowPowerCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 1;

    //
    // Tests methods
    //

    // Test Sleep Input Status Command
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterLowPowerCommandSleep_0_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{ OnTestSendClusterLowPowerCommandSleep_0_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterLowPowerCommandSleep_0()
    {
        ChipLogProgress(chipTool, "Low Power - Sleep Input Status Command: Sending command...");

        chip::Controller::LowPowerCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Sleep(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterLowPowerCommandSleep_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Low Power - Sleep Input Status Command: Failure Response");

        TV_LowPowerCluster * runner = reinterpret_cast<TV_LowPowerCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterLowPowerCommandSleep_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Low Power - Sleep Input Status Command: Success Response");

        TV_LowPowerCluster * runner = reinterpret_cast<TV_LowPowerCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TV_MediaInputCluster : public TestCommand
{
public:
    TV_MediaInputCluster() : TestCommand("TV_MediaInputCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TV_MediaInputCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterMediaInputCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterMediaInputCommandSelectInput_1();
            break;
        case 2:
            err = TestSendClusterMediaInputCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterMediaInputCommandHideInputStatus_3();
            break;
        case 4:
            err = TestSendClusterMediaInputCommandShowInputStatus_4();
            break;
        case 5:
            err = TestSendClusterMediaInputCommandRenameInput_5();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TV_MediaInputCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 6;

    //
    // Tests methods
    //

    // Test Read attribute media input list
    using SuccessCallback_0 = void (*)(void * context, uint16_t count, _MediaInputInfo * mediaInputList);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterMediaInputCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterMediaInputCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterMediaInputCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Media Input - Read attribute media input list: Sending command...");

        chip::Controller::MediaInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeMediaInputList(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaInputCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Input - Read attribute media input list: Failure Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaInputCommandReadAttribute_0_SuccessResponse(void * context, uint16_t count,
                                                                                  _MediaInputInfo * mediaInputList)
    {
        ChipLogProgress(chipTool, "Media Input - Read attribute media input list: Success Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 2)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "[object Object],[object Object]");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Select Input Command
    using SuccessCallback_1 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterMediaInputCommandSelectInput_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterMediaInputCommandSelectInput_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterMediaInputCommandSelectInput_1()
    {
        ChipLogProgress(chipTool, "Media Input - Select Input Command: Sending command...");

        chip::Controller::MediaInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t indexArgument = 1;
        err                   = cluster.SelectInput(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel(), indexArgument);

        return err;
    }

    static void OnTestSendClusterMediaInputCommandSelectInput_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Input - Select Input Command: Failure Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaInputCommandSelectInput_1_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Media Input - Select Input Command: Success Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current input list
    using SuccessCallback_2 = void (*)(void * context, uint8_t currentMediaInput);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterMediaInputCommandReadAttribute_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterMediaInputCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterMediaInputCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "Media Input - Read current input list: Sending command...");

        chip::Controller::MediaInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentMediaInput(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaInputCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Input - Read current input list: Failure Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaInputCommandReadAttribute_2_SuccessResponse(void * context, uint8_t currentMediaInput)
    {
        ChipLogProgress(chipTool, "Media Input - Read current input list: Success Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (currentMediaInput != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Hide Input Status Command
    using SuccessCallback_3 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterMediaInputCommandHideInputStatus_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterMediaInputCommandHideInputStatus_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterMediaInputCommandHideInputStatus_3()
    {
        ChipLogProgress(chipTool, "Media Input - Hide Input Status Command: Sending command...");

        chip::Controller::MediaInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.HideInputStatus(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaInputCommandHideInputStatus_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Input - Hide Input Status Command: Failure Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaInputCommandHideInputStatus_3_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Media Input - Hide Input Status Command: Success Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Show Input Status Command
    using SuccessCallback_4 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterMediaInputCommandShowInputStatus_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterMediaInputCommandShowInputStatus_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterMediaInputCommandShowInputStatus_4()
    {
        ChipLogProgress(chipTool, "Media Input - Show Input Status Command: Sending command...");

        chip::Controller::MediaInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ShowInputStatus(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterMediaInputCommandShowInputStatus_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Input - Show Input Status Command: Failure Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaInputCommandShowInputStatus_4_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Media Input - Show Input Status Command: Success Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Rename Input Command
    using SuccessCallback_5 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterMediaInputCommandRenameInput_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterMediaInputCommandRenameInput_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterMediaInputCommandRenameInput_5()
    {
        ChipLogProgress(chipTool, "Media Input - Rename Input Command: Sending command...");

        chip::Controller::MediaInputCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t indexArgument       = 1;
        chip::ByteSpan nameArgument = chip::ByteSpan(chip::Uint8::from_const_char("newName"), strlen("newName"));
        err = cluster.RenameInput(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel(), indexArgument, nameArgument);

        return err;
    }

    static void OnTestSendClusterMediaInputCommandRenameInput_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Media Input - Rename Input Command: Failure Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterMediaInputCommandRenameInput_5_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Media Input - Rename Input Command: Success Response");

        TV_MediaInputCluster * runner = reinterpret_cast<TV_MediaInputCluster *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class TestCluster : public TestCommand
{
public:
    TestCluster() : TestCommand("TestCluster"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "TestCluster: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterTestClusterCommandTest_0();
            break;
        case 1:
            err = TestSendClusterTestClusterCommandTestNotHandled_1();
            break;
        case 2:
            err = TestSendClusterTestClusterCommandTestSpecific_2();
            break;
        case 3:
            err = TestSendClusterTestClusterCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterTestClusterCommandWriteAttribute_4();
            break;
        case 5:
            err = TestSendClusterTestClusterCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterTestClusterCommandWriteAttribute_6();
            break;
        case 7:
            err = TestSendClusterTestClusterCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterTestClusterCommandReadAttribute_8();
            break;
        case 9:
            err = TestSendClusterTestClusterCommandWriteAttribute_9();
            break;
        case 10:
            err = TestSendClusterTestClusterCommandReadAttribute_10();
            break;
        case 11:
            err = TestSendClusterTestClusterCommandWriteAttribute_11();
            break;
        case 12:
            err = TestSendClusterTestClusterCommandReadAttribute_12();
            break;
        case 13:
            err = TestSendClusterTestClusterCommandReadAttribute_13();
            break;
        case 14:
            err = TestSendClusterTestClusterCommandWriteAttribute_14();
            break;
        case 15:
            err = TestSendClusterTestClusterCommandReadAttribute_15();
            break;
        case 16:
            err = TestSendClusterTestClusterCommandWriteAttribute_16();
            break;
        case 17:
            err = TestSendClusterTestClusterCommandReadAttribute_17();
            break;
        case 18:
            err = TestSendClusterTestClusterCommandReadAttribute_18();
            break;
        case 19:
            err = TestSendClusterTestClusterCommandWriteAttribute_19();
            break;
        case 20:
            err = TestSendClusterTestClusterCommandReadAttribute_20();
            break;
        case 21:
            err = TestSendClusterTestClusterCommandWriteAttribute_21();
            break;
        case 22:
            err = TestSendClusterTestClusterCommandReadAttribute_22();
            break;
        case 23:
            err = TestSendClusterTestClusterCommandReadAttribute_23();
            break;
        case 24:
            err = TestSendClusterTestClusterCommandWriteAttribute_24();
            break;
        case 25:
            err = TestSendClusterTestClusterCommandReadAttribute_25();
            break;
        case 26:
            err = TestSendClusterTestClusterCommandWriteAttribute_26();
            break;
        case 27:
            err = TestSendClusterTestClusterCommandReadAttribute_27();
            break;
        case 28:
            err = TestSendClusterTestClusterCommandReadAttribute_28();
            break;
        case 29:
            err = TestSendClusterTestClusterCommandWriteAttribute_29();
            break;
        case 30:
            err = TestSendClusterTestClusterCommandReadAttribute_30();
            break;
        case 31:
            err = TestSendClusterTestClusterCommandWriteAttribute_31();
            break;
        case 32:
            err = TestSendClusterTestClusterCommandReadAttribute_32();
            break;
        case 33:
            err = TestSendClusterTestClusterCommandReadAttribute_33();
            break;
        case 34:
            err = TestSendClusterTestClusterCommandWriteAttribute_34();
            break;
        case 35:
            err = TestSendClusterTestClusterCommandReadAttribute_35();
            break;
        case 36:
            err = TestSendClusterTestClusterCommandWriteAttribute_36();
            break;
        case 37:
            err = TestSendClusterTestClusterCommandReadAttribute_37();
            break;
        case 38:
            err = TestSendClusterTestClusterCommandReadAttribute_38();
            break;
        case 39:
            err = TestSendClusterTestClusterCommandWriteAttribute_39();
            break;
        case 40:
            err = TestSendClusterTestClusterCommandReadAttribute_40();
            break;
        case 41:
            err = TestSendClusterTestClusterCommandWriteAttribute_41();
            break;
        case 42:
            err = TestSendClusterTestClusterCommandReadAttribute_42();
            break;
        case 43:
            err = TestSendClusterTestClusterCommandReadAttribute_43();
            break;
        case 44:
            err = TestSendClusterTestClusterCommandWriteAttribute_44();
            break;
        case 45:
            err = TestSendClusterTestClusterCommandReadAttribute_45();
            break;
        case 46:
            err = TestSendClusterTestClusterCommandWriteAttribute_46();
            break;
        case 47:
            err = TestSendClusterTestClusterCommandReadAttribute_47();
            break;
        case 48:
            err = TestSendClusterTestClusterCommandReadAttribute_48();
            break;
        case 49:
            err = TestSendClusterTestClusterCommandWriteAttribute_49();
            break;
        case 50:
            err = TestSendClusterTestClusterCommandReadAttribute_50();
            break;
        case 51:
            err = TestSendClusterTestClusterCommandWriteAttribute_51();
            break;
        case 52:
            err = TestSendClusterTestClusterCommandReadAttribute_52();
            break;
        case 53:
            err = TestSendClusterTestClusterCommandWriteAttribute_53();
            break;
        case 54:
            err = TestSendClusterTestClusterCommandReadAttribute_54();
            break;
        case 55:
            err = TestSendClusterTestClusterCommandReadAttribute_55();
            break;
        case 56:
            err = TestSendClusterTestClusterCommandWriteAttribute_56();
            break;
        case 57:
            err = TestSendClusterTestClusterCommandReadAttribute_57();
            break;
        case 58:
            err = TestSendClusterTestClusterCommandWriteAttribute_58();
            break;
        case 59:
            err = TestSendClusterTestClusterCommandReadAttribute_59();
            break;
        case 60:
            err = TestSendClusterTestClusterCommandWriteAttribute_60();
            break;
        case 61:
            err = TestSendClusterTestClusterCommandReadAttribute_61();
            break;
        case 62:
            err = TestSendClusterTestClusterCommandReadAttribute_62();
            break;
        case 63:
            err = TestSendClusterTestClusterCommandWriteAttribute_63();
            break;
        case 64:
            err = TestSendClusterTestClusterCommandReadAttribute_64();
            break;
        case 65:
            err = TestSendClusterTestClusterCommandWriteAttribute_65();
            break;
        case 66:
            err = TestSendClusterTestClusterCommandReadAttribute_66();
            break;
        case 67:
            err = TestSendClusterTestClusterCommandWriteAttribute_67();
            break;
        case 68:
            err = TestSendClusterTestClusterCommandReadAttribute_68();
            break;
        case 69:
            err = TestSendClusterTestClusterCommandReadAttribute_69();
            break;
        case 70:
            err = TestSendClusterTestClusterCommandWriteAttribute_70();
            break;
        case 71:
            err = TestSendClusterTestClusterCommandReadAttribute_71();
            break;
        case 72:
            err = TestSendClusterTestClusterCommandWriteAttribute_72();
            break;
        case 73:
            err = TestSendClusterTestClusterCommandReadAttribute_73();
            break;
        case 74:
            err = TestSendClusterTestClusterCommandWriteAttribute_74();
            break;
        case 75:
            err = TestSendClusterTestClusterCommandReadAttribute_75();
            break;
        case 76:
            err = TestSendClusterTestClusterCommandReadAttribute_76();
            break;
        case 77:
            err = TestSendClusterTestClusterCommandWriteAttribute_77();
            break;
        case 78:
            err = TestSendClusterTestClusterCommandReadAttribute_78();
            break;
        case 79:
            err = TestSendClusterTestClusterCommandWriteAttribute_79();
            break;
        case 80:
            err = TestSendClusterTestClusterCommandReadAttribute_80();
            break;
        case 81:
            err = TestSendClusterTestClusterCommandReadAttribute_81();
            break;
        case 82:
            err = TestSendClusterTestClusterCommandWriteAttribute_82();
            break;
        case 83:
            err = TestSendClusterTestClusterCommandReadAttribute_83();
            break;
        case 84:
            err = TestSendClusterTestClusterCommandWriteAttribute_84();
            break;
        case 85:
            err = TestSendClusterTestClusterCommandReadAttribute_85();
            break;
        case 86:
            err = TestSendClusterTestClusterCommandReadAttribute_86();
            break;
        case 87:
            err = TestSendClusterTestClusterCommandWriteAttribute_87();
            break;
        case 88:
            err = TestSendClusterTestClusterCommandReadAttribute_88();
            break;
        case 89:
            err = TestSendClusterTestClusterCommandWriteAttribute_89();
            break;
        case 90:
            err = TestSendClusterTestClusterCommandReadAttribute_90();
            break;
        case 91:
            err = TestSendClusterTestClusterCommandWriteAttribute_91();
            break;
        case 92:
            err = TestSendClusterTestClusterCommandReadAttribute_92();
            break;
        case 93:
            err = TestSendClusterTestClusterCommandWriteAttribute_93();
            break;
        case 94:
            err = TestSendClusterTestClusterCommandReadAttribute_94();
            break;
        case 95:
            err = TestSendClusterTestClusterCommandWriteAttribute_95();
            break;
        case 96:
            err = TestSendClusterTestClusterCommandReadAttribute_96();
            break;
        case 97:
            err = TestSendClusterTestClusterCommandWriteAttribute_97();
            break;
        case 98:
            err = TestSendClusterTestClusterCommandWriteAttribute_98();
            break;
        case 99:
            err = TestSendClusterTestClusterCommandWriteAttribute_99();
            break;
        case 100:
            err = TestSendClusterTestClusterCommandReadAttribute_100();
            break;
        case 101:
            err = TestSendClusterTestClusterCommandWriteAttribute_101();
            break;
        case 102:
            err = TestSendClusterTestClusterCommandReadAttribute_102();
            break;
        case 103:
            err = TestSendClusterTestClusterCommandWriteAttribute_103();
            break;
        case 104:
            err = TestSendClusterTestClusterCommandReadAttribute_104();
            break;
        case 105:
            err = TestSendClusterTestClusterCommandReadAttribute_105();
            break;
        case 106:
            err = TestSendClusterTestClusterCommandReadAttribute_106();
            break;
        case 107:
            err = TestSendClusterTestClusterCommandReadAttribute_107();
            break;
        case 108:
            err = TestSendClusterTestClusterCommandWriteAttribute_108();
            break;
        case 109:
            err = TestSendClusterTestClusterCommandTest_109();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "TestCluster: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 110;

    //
    // Tests methods
    //

    // Test Send Test Command
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterTestClusterCommandTest_0_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterTestClusterCommandTest_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandTest_0()
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Command: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Test(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandTest_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Command: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandTest_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Command: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Test Not Handled Command
    using SuccessCallback_1 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterTestClusterCommandTestNotHandled_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterTestClusterCommandTestNotHandled_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 1;

    CHIP_ERROR TestSendClusterTestClusterCommandTestNotHandled_1()
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Not Handled Command: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.TestNotHandled(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandTestNotHandled_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Not Handled Command: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandTestNotHandled_1_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Not Handled Command: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Test Specific Command
    using SuccessCallback_2 = void (*)(void * context, uint8_t returnValue);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterTestClusterCommandTestSpecific_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterTestClusterCommandTestSpecific_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandTestSpecific_2()
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Specific Command: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.TestSpecific(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandTestSpecific_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Specific Command: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandTestSpecific_2_SuccessResponse(void * context, uint8_t returnValue)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Specific Command: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (returnValue != 7)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "7");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BOOLEAN Default Value
    using SuccessCallback_3 = void (*)(void * context, uint8_t boolean);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterTestClusterCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterTestClusterCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBoolean(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_3_SuccessResponse(void * context, uint8_t boolean)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (boolean != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BOOLEAN True
    using SuccessCallback_4 = void (*)(void * context, uint8_t boolean);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterTestClusterCommandWriteAttribute_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterTestClusterCommandWriteAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_4()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BOOLEAN True: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t booleanArgument = 1;
        err = cluster.WriteAttributeBoolean(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel(), booleanArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BOOLEAN True: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_4_SuccessResponse(void * context, uint8_t boolean)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BOOLEAN True: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BOOLEAN True
    using SuccessCallback_5 = void (*)(void * context, uint8_t boolean);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterTestClusterCommandReadAttribute_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterTestClusterCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN True: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBoolean(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN True: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_5_SuccessResponse(void * context, uint8_t boolean)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN True: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (boolean != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BOOLEAN False
    using SuccessCallback_6 = void (*)(void * context, uint8_t boolean);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterTestClusterCommandWriteAttribute_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterTestClusterCommandWriteAttribute_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_6()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BOOLEAN False: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t booleanArgument = 0;
        err = cluster.WriteAttributeBoolean(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel(), booleanArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BOOLEAN False: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_6_SuccessResponse(void * context, uint8_t boolean)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BOOLEAN False: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BOOLEAN False
    using SuccessCallback_7 = void (*)(void * context, uint8_t boolean);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterTestClusterCommandReadAttribute_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterTestClusterCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_7()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN False: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBoolean(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN False: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_7_SuccessResponse(void * context, uint8_t boolean)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BOOLEAN False: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (boolean != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP8 Default Value
    using SuccessCallback_8 = void (*)(void * context, uint8_t bitmap8);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterTestClusterCommandReadAttribute_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterTestClusterCommandReadAttribute_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_8()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap8(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_8_SuccessResponse(void * context, uint8_t bitmap8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap8 != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP8 Max Value
    using SuccessCallback_9 = void (*)(void * context, uint8_t bitmap8);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterTestClusterCommandWriteAttribute_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterTestClusterCommandWriteAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_9()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP8 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t bitmap8Argument = 255;
        err = cluster.WriteAttributeBitmap8(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel(), bitmap8Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP8 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_9_SuccessResponse(void * context, uint8_t bitmap8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP8 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP8 Max Value
    using SuccessCallback_10 = void (*)(void * context, uint8_t bitmap8);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterTestClusterCommandReadAttribute_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterTestClusterCommandReadAttribute_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_10()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap8(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_10_SuccessResponse(void * context, uint8_t bitmap8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap8 != 255)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "255");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP8 Min Value
    using SuccessCallback_11 = void (*)(void * context, uint8_t bitmap8);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterTestClusterCommandWriteAttribute_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterTestClusterCommandWriteAttribute_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_11()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP8 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t bitmap8Argument = 0;
        err = cluster.WriteAttributeBitmap8(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel(), bitmap8Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP8 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_11_SuccessResponse(void * context, uint8_t bitmap8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP8 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP8 Min Value
    using SuccessCallback_12 = void (*)(void * context, uint8_t bitmap8);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{
        OnTestSendClusterTestClusterCommandReadAttribute_12_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{
        OnTestSendClusterTestClusterCommandReadAttribute_12_FailureResponse, this
    };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_12()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap8(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_12_SuccessResponse(void * context, uint8_t bitmap8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP8 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap8 != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP16 Default Value
    using SuccessCallback_13 = void (*)(void * context, uint16_t bitmap16);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterTestClusterCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterTestClusterCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_13()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap16(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_13_SuccessResponse(void * context, uint16_t bitmap16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap16 != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP16 Max Value
    using SuccessCallback_14 = void (*)(void * context, uint16_t bitmap16);
    chip::Callback::Callback<SuccessCallback_14> mOnSuccessCallback_14{
        OnTestSendClusterTestClusterCommandWriteAttribute_14_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_14{
        OnTestSendClusterTestClusterCommandWriteAttribute_14_FailureResponse, this
    };
    bool mIsFailureExpected_14 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_14()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP16 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t bitmap16Argument = 65535U;
        err = cluster.WriteAttributeBitmap16(mOnSuccessCallback_14.Cancel(), mOnFailureCallback_14.Cancel(), bitmap16Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_14_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP16 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_14 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_14_SuccessResponse(void * context, uint16_t bitmap16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP16 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_14 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP16 Max Value
    using SuccessCallback_15 = void (*)(void * context, uint16_t bitmap16);
    chip::Callback::Callback<SuccessCallback_15> mOnSuccessCallback_15{
        OnTestSendClusterTestClusterCommandReadAttribute_15_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_15{
        OnTestSendClusterTestClusterCommandReadAttribute_15_FailureResponse, this
    };
    bool mIsFailureExpected_15 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_15()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap16(mOnSuccessCallback_15.Cancel(), mOnFailureCallback_15.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_15_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_15 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_15_SuccessResponse(void * context, uint16_t bitmap16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_15 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap16 != 65535U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "65535");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP16 Min Value
    using SuccessCallback_16 = void (*)(void * context, uint16_t bitmap16);
    chip::Callback::Callback<SuccessCallback_16> mOnSuccessCallback_16{
        OnTestSendClusterTestClusterCommandWriteAttribute_16_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_16{
        OnTestSendClusterTestClusterCommandWriteAttribute_16_FailureResponse, this
    };
    bool mIsFailureExpected_16 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_16()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP16 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t bitmap16Argument = 0U;
        err = cluster.WriteAttributeBitmap16(mOnSuccessCallback_16.Cancel(), mOnFailureCallback_16.Cancel(), bitmap16Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_16_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP16 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_16 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_16_SuccessResponse(void * context, uint16_t bitmap16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP16 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_16 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP16 Min Value
    using SuccessCallback_17 = void (*)(void * context, uint16_t bitmap16);
    chip::Callback::Callback<SuccessCallback_17> mOnSuccessCallback_17{
        OnTestSendClusterTestClusterCommandReadAttribute_17_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_17{
        OnTestSendClusterTestClusterCommandReadAttribute_17_FailureResponse, this
    };
    bool mIsFailureExpected_17 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_17()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap16(mOnSuccessCallback_17.Cancel(), mOnFailureCallback_17.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_17_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_17 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_17_SuccessResponse(void * context, uint16_t bitmap16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP16 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_17 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap16 != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP32 Default Value
    using SuccessCallback_18 = void (*)(void * context, uint32_t bitmap32);
    chip::Callback::Callback<SuccessCallback_18> mOnSuccessCallback_18{
        OnTestSendClusterTestClusterCommandReadAttribute_18_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_18{
        OnTestSendClusterTestClusterCommandReadAttribute_18_FailureResponse, this
    };
    bool mIsFailureExpected_18 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_18()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap32(mOnSuccessCallback_18.Cancel(), mOnFailureCallback_18.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_18_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_18 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_18_SuccessResponse(void * context, uint32_t bitmap32)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_18 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap32 != 0UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP32 Max Value
    using SuccessCallback_19 = void (*)(void * context, uint32_t bitmap32);
    chip::Callback::Callback<SuccessCallback_19> mOnSuccessCallback_19{
        OnTestSendClusterTestClusterCommandWriteAttribute_19_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_19{
        OnTestSendClusterTestClusterCommandWriteAttribute_19_FailureResponse, this
    };
    bool mIsFailureExpected_19 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_19()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP32 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint32_t bitmap32Argument = 4294967295UL;
        err = cluster.WriteAttributeBitmap32(mOnSuccessCallback_19.Cancel(), mOnFailureCallback_19.Cancel(), bitmap32Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_19_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP32 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_19 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_19_SuccessResponse(void * context, uint32_t bitmap32)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP32 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_19 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP32 Max Value
    using SuccessCallback_20 = void (*)(void * context, uint32_t bitmap32);
    chip::Callback::Callback<SuccessCallback_20> mOnSuccessCallback_20{
        OnTestSendClusterTestClusterCommandReadAttribute_20_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_20{
        OnTestSendClusterTestClusterCommandReadAttribute_20_FailureResponse, this
    };
    bool mIsFailureExpected_20 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_20()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap32(mOnSuccessCallback_20.Cancel(), mOnFailureCallback_20.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_20_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_20 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_20_SuccessResponse(void * context, uint32_t bitmap32)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_20 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap32 != 4294967295UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "4294967295");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP32 Min Value
    using SuccessCallback_21 = void (*)(void * context, uint32_t bitmap32);
    chip::Callback::Callback<SuccessCallback_21> mOnSuccessCallback_21{
        OnTestSendClusterTestClusterCommandWriteAttribute_21_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_21{
        OnTestSendClusterTestClusterCommandWriteAttribute_21_FailureResponse, this
    };
    bool mIsFailureExpected_21 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_21()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP32 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint32_t bitmap32Argument = 0UL;
        err = cluster.WriteAttributeBitmap32(mOnSuccessCallback_21.Cancel(), mOnFailureCallback_21.Cancel(), bitmap32Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_21_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP32 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_21 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_21_SuccessResponse(void * context, uint32_t bitmap32)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP32 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_21 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP32 Min Value
    using SuccessCallback_22 = void (*)(void * context, uint32_t bitmap32);
    chip::Callback::Callback<SuccessCallback_22> mOnSuccessCallback_22{
        OnTestSendClusterTestClusterCommandReadAttribute_22_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_22{
        OnTestSendClusterTestClusterCommandReadAttribute_22_FailureResponse, this
    };
    bool mIsFailureExpected_22 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_22()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap32(mOnSuccessCallback_22.Cancel(), mOnFailureCallback_22.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_22_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_22 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_22_SuccessResponse(void * context, uint32_t bitmap32)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP32 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_22 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap32 != 0UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP64 Default Value
    using SuccessCallback_23 = void (*)(void * context, uint64_t bitmap64);
    chip::Callback::Callback<SuccessCallback_23> mOnSuccessCallback_23{
        OnTestSendClusterTestClusterCommandReadAttribute_23_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_23{
        OnTestSendClusterTestClusterCommandReadAttribute_23_FailureResponse, this
    };
    bool mIsFailureExpected_23 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_23()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap64(mOnSuccessCallback_23.Cancel(), mOnFailureCallback_23.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_23_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_23 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_23_SuccessResponse(void * context, uint64_t bitmap64)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_23 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap64 != 0ULL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP64 Max Value
    using SuccessCallback_24 = void (*)(void * context, uint64_t bitmap64);
    chip::Callback::Callback<SuccessCallback_24> mOnSuccessCallback_24{
        OnTestSendClusterTestClusterCommandWriteAttribute_24_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_24{
        OnTestSendClusterTestClusterCommandWriteAttribute_24_FailureResponse, this
    };
    bool mIsFailureExpected_24 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_24()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP64 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t bitmap64Argument = 18446744073709551615ULL;
        err = cluster.WriteAttributeBitmap64(mOnSuccessCallback_24.Cancel(), mOnFailureCallback_24.Cancel(), bitmap64Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_24_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP64 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_24 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_24_SuccessResponse(void * context, uint64_t bitmap64)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP64 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_24 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP64 Max Value
    using SuccessCallback_25 = void (*)(void * context, uint64_t bitmap64);
    chip::Callback::Callback<SuccessCallback_25> mOnSuccessCallback_25{
        OnTestSendClusterTestClusterCommandReadAttribute_25_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_25{
        OnTestSendClusterTestClusterCommandReadAttribute_25_FailureResponse, this
    };
    bool mIsFailureExpected_25 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_25()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap64(mOnSuccessCallback_25.Cancel(), mOnFailureCallback_25.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_25_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_25 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_25_SuccessResponse(void * context, uint64_t bitmap64)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_25 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap64 != 18446744073709551615ULL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "18446744073709551615");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute BITMAP64 Min Value
    using SuccessCallback_26 = void (*)(void * context, uint64_t bitmap64);
    chip::Callback::Callback<SuccessCallback_26> mOnSuccessCallback_26{
        OnTestSendClusterTestClusterCommandWriteAttribute_26_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_26{
        OnTestSendClusterTestClusterCommandWriteAttribute_26_FailureResponse, this
    };
    bool mIsFailureExpected_26 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_26()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP64 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t bitmap64Argument = 0ULL;
        err = cluster.WriteAttributeBitmap64(mOnSuccessCallback_26.Cancel(), mOnFailureCallback_26.Cancel(), bitmap64Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_26_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP64 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_26 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_26_SuccessResponse(void * context, uint64_t bitmap64)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute BITMAP64 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_26 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute BITMAP64 Min Value
    using SuccessCallback_27 = void (*)(void * context, uint64_t bitmap64);
    chip::Callback::Callback<SuccessCallback_27> mOnSuccessCallback_27{
        OnTestSendClusterTestClusterCommandReadAttribute_27_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_27{
        OnTestSendClusterTestClusterCommandReadAttribute_27_FailureResponse, this
    };
    bool mIsFailureExpected_27 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_27()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeBitmap64(mOnSuccessCallback_27.Cancel(), mOnFailureCallback_27.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_27_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_27 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_27_SuccessResponse(void * context, uint64_t bitmap64)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute BITMAP64 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_27 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (bitmap64 != 0ULL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8U Default Value
    using SuccessCallback_28 = void (*)(void * context, uint8_t int8u);
    chip::Callback::Callback<SuccessCallback_28> mOnSuccessCallback_28{
        OnTestSendClusterTestClusterCommandReadAttribute_28_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_28{
        OnTestSendClusterTestClusterCommandReadAttribute_28_FailureResponse, this
    };
    bool mIsFailureExpected_28 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_28()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8u(mOnSuccessCallback_28.Cancel(), mOnFailureCallback_28.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_28_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_28 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_28_SuccessResponse(void * context, uint8_t int8u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_28 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8u != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT8U Max Value
    using SuccessCallback_29 = void (*)(void * context, uint8_t int8u);
    chip::Callback::Callback<SuccessCallback_29> mOnSuccessCallback_29{
        OnTestSendClusterTestClusterCommandWriteAttribute_29_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_29{
        OnTestSendClusterTestClusterCommandWriteAttribute_29_FailureResponse, this
    };
    bool mIsFailureExpected_29 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_29()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t int8uArgument = 255;
        err = cluster.WriteAttributeInt8u(mOnSuccessCallback_29.Cancel(), mOnFailureCallback_29.Cancel(), int8uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_29_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_29 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_29_SuccessResponse(void * context, uint8_t int8u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_29 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8U Max Value
    using SuccessCallback_30 = void (*)(void * context, uint8_t int8u);
    chip::Callback::Callback<SuccessCallback_30> mOnSuccessCallback_30{
        OnTestSendClusterTestClusterCommandReadAttribute_30_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_30{
        OnTestSendClusterTestClusterCommandReadAttribute_30_FailureResponse, this
    };
    bool mIsFailureExpected_30 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_30()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8u(mOnSuccessCallback_30.Cancel(), mOnFailureCallback_30.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_30_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_30 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_30_SuccessResponse(void * context, uint8_t int8u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_30 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8u != 255)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "255");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT8U Min Value
    using SuccessCallback_31 = void (*)(void * context, uint8_t int8u);
    chip::Callback::Callback<SuccessCallback_31> mOnSuccessCallback_31{
        OnTestSendClusterTestClusterCommandWriteAttribute_31_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_31{
        OnTestSendClusterTestClusterCommandWriteAttribute_31_FailureResponse, this
    };
    bool mIsFailureExpected_31 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_31()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t int8uArgument = 0;
        err = cluster.WriteAttributeInt8u(mOnSuccessCallback_31.Cancel(), mOnFailureCallback_31.Cancel(), int8uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_31_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_31 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_31_SuccessResponse(void * context, uint8_t int8u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_31 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8U Min Value
    using SuccessCallback_32 = void (*)(void * context, uint8_t int8u);
    chip::Callback::Callback<SuccessCallback_32> mOnSuccessCallback_32{
        OnTestSendClusterTestClusterCommandReadAttribute_32_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_32{
        OnTestSendClusterTestClusterCommandReadAttribute_32_FailureResponse, this
    };
    bool mIsFailureExpected_32 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_32()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8u(mOnSuccessCallback_32.Cancel(), mOnFailureCallback_32.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_32_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_32 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_32_SuccessResponse(void * context, uint8_t int8u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_32 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8u != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16U Default Value
    using SuccessCallback_33 = void (*)(void * context, uint16_t int16u);
    chip::Callback::Callback<SuccessCallback_33> mOnSuccessCallback_33{
        OnTestSendClusterTestClusterCommandReadAttribute_33_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_33{
        OnTestSendClusterTestClusterCommandReadAttribute_33_FailureResponse, this
    };
    bool mIsFailureExpected_33 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_33()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16u(mOnSuccessCallback_33.Cancel(), mOnFailureCallback_33.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_33_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_33 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_33_SuccessResponse(void * context, uint16_t int16u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_33 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16u != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT16U Max Value
    using SuccessCallback_34 = void (*)(void * context, uint16_t int16u);
    chip::Callback::Callback<SuccessCallback_34> mOnSuccessCallback_34{
        OnTestSendClusterTestClusterCommandWriteAttribute_34_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_34{
        OnTestSendClusterTestClusterCommandWriteAttribute_34_FailureResponse, this
    };
    bool mIsFailureExpected_34 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_34()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t int16uArgument = 65535U;
        err = cluster.WriteAttributeInt16u(mOnSuccessCallback_34.Cancel(), mOnFailureCallback_34.Cancel(), int16uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_34_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_34 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_34_SuccessResponse(void * context, uint16_t int16u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_34 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16U Max Value
    using SuccessCallback_35 = void (*)(void * context, uint16_t int16u);
    chip::Callback::Callback<SuccessCallback_35> mOnSuccessCallback_35{
        OnTestSendClusterTestClusterCommandReadAttribute_35_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_35{
        OnTestSendClusterTestClusterCommandReadAttribute_35_FailureResponse, this
    };
    bool mIsFailureExpected_35 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_35()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16u(mOnSuccessCallback_35.Cancel(), mOnFailureCallback_35.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_35_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_35 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_35_SuccessResponse(void * context, uint16_t int16u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_35 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16u != 65535U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "65535");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT16U Min Value
    using SuccessCallback_36 = void (*)(void * context, uint16_t int16u);
    chip::Callback::Callback<SuccessCallback_36> mOnSuccessCallback_36{
        OnTestSendClusterTestClusterCommandWriteAttribute_36_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_36{
        OnTestSendClusterTestClusterCommandWriteAttribute_36_FailureResponse, this
    };
    bool mIsFailureExpected_36 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_36()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t int16uArgument = 0U;
        err = cluster.WriteAttributeInt16u(mOnSuccessCallback_36.Cancel(), mOnFailureCallback_36.Cancel(), int16uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_36_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_36 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_36_SuccessResponse(void * context, uint16_t int16u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_36 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16U Min Value
    using SuccessCallback_37 = void (*)(void * context, uint16_t int16u);
    chip::Callback::Callback<SuccessCallback_37> mOnSuccessCallback_37{
        OnTestSendClusterTestClusterCommandReadAttribute_37_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_37{
        OnTestSendClusterTestClusterCommandReadAttribute_37_FailureResponse, this
    };
    bool mIsFailureExpected_37 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_37()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16u(mOnSuccessCallback_37.Cancel(), mOnFailureCallback_37.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_37_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_37 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_37_SuccessResponse(void * context, uint16_t int16u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_37 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16u != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32U Default Value
    using SuccessCallback_38 = void (*)(void * context, uint32_t int32u);
    chip::Callback::Callback<SuccessCallback_38> mOnSuccessCallback_38{
        OnTestSendClusterTestClusterCommandReadAttribute_38_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_38{
        OnTestSendClusterTestClusterCommandReadAttribute_38_FailureResponse, this
    };
    bool mIsFailureExpected_38 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_38()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32u(mOnSuccessCallback_38.Cancel(), mOnFailureCallback_38.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_38_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_38 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_38_SuccessResponse(void * context, uint32_t int32u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_38 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32u != 0UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT32U Max Value
    using SuccessCallback_39 = void (*)(void * context, uint32_t int32u);
    chip::Callback::Callback<SuccessCallback_39> mOnSuccessCallback_39{
        OnTestSendClusterTestClusterCommandWriteAttribute_39_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_39{
        OnTestSendClusterTestClusterCommandWriteAttribute_39_FailureResponse, this
    };
    bool mIsFailureExpected_39 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_39()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint32_t int32uArgument = 4294967295UL;
        err = cluster.WriteAttributeInt32u(mOnSuccessCallback_39.Cancel(), mOnFailureCallback_39.Cancel(), int32uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_39_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_39 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_39_SuccessResponse(void * context, uint32_t int32u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_39 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32U Max Value
    using SuccessCallback_40 = void (*)(void * context, uint32_t int32u);
    chip::Callback::Callback<SuccessCallback_40> mOnSuccessCallback_40{
        OnTestSendClusterTestClusterCommandReadAttribute_40_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_40{
        OnTestSendClusterTestClusterCommandReadAttribute_40_FailureResponse, this
    };
    bool mIsFailureExpected_40 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_40()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32u(mOnSuccessCallback_40.Cancel(), mOnFailureCallback_40.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_40_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_40 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_40_SuccessResponse(void * context, uint32_t int32u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_40 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32u != 4294967295UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "4294967295");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT32U Min Value
    using SuccessCallback_41 = void (*)(void * context, uint32_t int32u);
    chip::Callback::Callback<SuccessCallback_41> mOnSuccessCallback_41{
        OnTestSendClusterTestClusterCommandWriteAttribute_41_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_41{
        OnTestSendClusterTestClusterCommandWriteAttribute_41_FailureResponse, this
    };
    bool mIsFailureExpected_41 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_41()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint32_t int32uArgument = 0UL;
        err = cluster.WriteAttributeInt32u(mOnSuccessCallback_41.Cancel(), mOnFailureCallback_41.Cancel(), int32uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_41_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_41 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_41_SuccessResponse(void * context, uint32_t int32u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_41 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32U Min Value
    using SuccessCallback_42 = void (*)(void * context, uint32_t int32u);
    chip::Callback::Callback<SuccessCallback_42> mOnSuccessCallback_42{
        OnTestSendClusterTestClusterCommandReadAttribute_42_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_42{
        OnTestSendClusterTestClusterCommandReadAttribute_42_FailureResponse, this
    };
    bool mIsFailureExpected_42 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_42()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32u(mOnSuccessCallback_42.Cancel(), mOnFailureCallback_42.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_42_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_42 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_42_SuccessResponse(void * context, uint32_t int32u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_42 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32u != 0UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64U Default Value
    using SuccessCallback_43 = void (*)(void * context, uint64_t int64u);
    chip::Callback::Callback<SuccessCallback_43> mOnSuccessCallback_43{
        OnTestSendClusterTestClusterCommandReadAttribute_43_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_43{
        OnTestSendClusterTestClusterCommandReadAttribute_43_FailureResponse, this
    };
    bool mIsFailureExpected_43 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_43()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64u(mOnSuccessCallback_43.Cancel(), mOnFailureCallback_43.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_43_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_43 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_43_SuccessResponse(void * context, uint64_t int64u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_43 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64u != 0ULL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT64U Max Value
    using SuccessCallback_44 = void (*)(void * context, uint64_t int64u);
    chip::Callback::Callback<SuccessCallback_44> mOnSuccessCallback_44{
        OnTestSendClusterTestClusterCommandWriteAttribute_44_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_44{
        OnTestSendClusterTestClusterCommandWriteAttribute_44_FailureResponse, this
    };
    bool mIsFailureExpected_44 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_44()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t int64uArgument = 18446744073709551615ULL;
        err = cluster.WriteAttributeInt64u(mOnSuccessCallback_44.Cancel(), mOnFailureCallback_44.Cancel(), int64uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_44_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_44 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_44_SuccessResponse(void * context, uint64_t int64u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_44 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64U Max Value
    using SuccessCallback_45 = void (*)(void * context, uint64_t int64u);
    chip::Callback::Callback<SuccessCallback_45> mOnSuccessCallback_45{
        OnTestSendClusterTestClusterCommandReadAttribute_45_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_45{
        OnTestSendClusterTestClusterCommandReadAttribute_45_FailureResponse, this
    };
    bool mIsFailureExpected_45 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_45()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64u(mOnSuccessCallback_45.Cancel(), mOnFailureCallback_45.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_45_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_45 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_45_SuccessResponse(void * context, uint64_t int64u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_45 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64u != 18446744073709551615ULL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "18446744073709551615");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT64U Min Value
    using SuccessCallback_46 = void (*)(void * context, uint64_t int64u);
    chip::Callback::Callback<SuccessCallback_46> mOnSuccessCallback_46{
        OnTestSendClusterTestClusterCommandWriteAttribute_46_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_46{
        OnTestSendClusterTestClusterCommandWriteAttribute_46_FailureResponse, this
    };
    bool mIsFailureExpected_46 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_46()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint64_t int64uArgument = 0ULL;
        err = cluster.WriteAttributeInt64u(mOnSuccessCallback_46.Cancel(), mOnFailureCallback_46.Cancel(), int64uArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_46_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_46 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_46_SuccessResponse(void * context, uint64_t int64u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_46 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64U Min Value
    using SuccessCallback_47 = void (*)(void * context, uint64_t int64u);
    chip::Callback::Callback<SuccessCallback_47> mOnSuccessCallback_47{
        OnTestSendClusterTestClusterCommandReadAttribute_47_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_47{
        OnTestSendClusterTestClusterCommandReadAttribute_47_FailureResponse, this
    };
    bool mIsFailureExpected_47 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_47()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64u(mOnSuccessCallback_47.Cancel(), mOnFailureCallback_47.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_47_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_47 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_47_SuccessResponse(void * context, uint64_t int64u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64U Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_47 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64u != 0ULL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8S Default Value
    using SuccessCallback_48 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_48> mOnSuccessCallback_48{
        OnTestSendClusterTestClusterCommandReadAttribute_48_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_48{
        OnTestSendClusterTestClusterCommandReadAttribute_48_FailureResponse, this
    };
    bool mIsFailureExpected_48 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_48()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8s(mOnSuccessCallback_48.Cancel(), mOnFailureCallback_48.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_48_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_48 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_48_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_48 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8s != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT8S Max Value
    using SuccessCallback_49 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_49> mOnSuccessCallback_49{
        OnTestSendClusterTestClusterCommandWriteAttribute_49_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_49{
        OnTestSendClusterTestClusterCommandWriteAttribute_49_FailureResponse, this
    };
    bool mIsFailureExpected_49 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_49()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int8_t int8sArgument = 127;
        err = cluster.WriteAttributeInt8s(mOnSuccessCallback_49.Cancel(), mOnFailureCallback_49.Cancel(), int8sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_49_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_49 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_49_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_49 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8S Max Value
    using SuccessCallback_50 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_50> mOnSuccessCallback_50{
        OnTestSendClusterTestClusterCommandReadAttribute_50_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_50{
        OnTestSendClusterTestClusterCommandReadAttribute_50_FailureResponse, this
    };
    bool mIsFailureExpected_50 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_50()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8s(mOnSuccessCallback_50.Cancel(), mOnFailureCallback_50.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_50_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_50 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_50_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_50 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8s != 127)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "127");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT8S Min Value
    using SuccessCallback_51 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_51> mOnSuccessCallback_51{
        OnTestSendClusterTestClusterCommandWriteAttribute_51_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_51{
        OnTestSendClusterTestClusterCommandWriteAttribute_51_FailureResponse, this
    };
    bool mIsFailureExpected_51 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_51()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int8_t int8sArgument = -128;
        err = cluster.WriteAttributeInt8s(mOnSuccessCallback_51.Cancel(), mOnFailureCallback_51.Cancel(), int8sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_51_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_51 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_51_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_51 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8S Min Value
    using SuccessCallback_52 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_52> mOnSuccessCallback_52{
        OnTestSendClusterTestClusterCommandReadAttribute_52_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_52{
        OnTestSendClusterTestClusterCommandReadAttribute_52_FailureResponse, this
    };
    bool mIsFailureExpected_52 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_52()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8s(mOnSuccessCallback_52.Cancel(), mOnFailureCallback_52.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_52_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_52 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_52_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_52 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8s != -128)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "-128");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT8S Default Value
    using SuccessCallback_53 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_53> mOnSuccessCallback_53{
        OnTestSendClusterTestClusterCommandWriteAttribute_53_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_53{
        OnTestSendClusterTestClusterCommandWriteAttribute_53_FailureResponse, this
    };
    bool mIsFailureExpected_53 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_53()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int8_t int8sArgument = 0;
        err = cluster.WriteAttributeInt8s(mOnSuccessCallback_53.Cancel(), mOnFailureCallback_53.Cancel(), int8sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_53_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_53 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_53_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT8S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_53 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT8S Default Value
    using SuccessCallback_54 = void (*)(void * context, int8_t int8s);
    chip::Callback::Callback<SuccessCallback_54> mOnSuccessCallback_54{
        OnTestSendClusterTestClusterCommandReadAttribute_54_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_54{
        OnTestSendClusterTestClusterCommandReadAttribute_54_FailureResponse, this
    };
    bool mIsFailureExpected_54 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_54()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt8s(mOnSuccessCallback_54.Cancel(), mOnFailureCallback_54.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_54_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_54 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_54_SuccessResponse(void * context, int8_t int8s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT8S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_54 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int8s != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16S Default Value
    using SuccessCallback_55 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_55> mOnSuccessCallback_55{
        OnTestSendClusterTestClusterCommandReadAttribute_55_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_55{
        OnTestSendClusterTestClusterCommandReadAttribute_55_FailureResponse, this
    };
    bool mIsFailureExpected_55 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_55()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16s(mOnSuccessCallback_55.Cancel(), mOnFailureCallback_55.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_55_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_55 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_55_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_55 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16s != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT16S Max Value
    using SuccessCallback_56 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_56> mOnSuccessCallback_56{
        OnTestSendClusterTestClusterCommandWriteAttribute_56_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_56{
        OnTestSendClusterTestClusterCommandWriteAttribute_56_FailureResponse, this
    };
    bool mIsFailureExpected_56 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_56()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int16_t int16sArgument = 32767;
        err = cluster.WriteAttributeInt16s(mOnSuccessCallback_56.Cancel(), mOnFailureCallback_56.Cancel(), int16sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_56_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_56 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_56_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_56 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16S Max Value
    using SuccessCallback_57 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_57> mOnSuccessCallback_57{
        OnTestSendClusterTestClusterCommandReadAttribute_57_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_57{
        OnTestSendClusterTestClusterCommandReadAttribute_57_FailureResponse, this
    };
    bool mIsFailureExpected_57 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_57()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16s(mOnSuccessCallback_57.Cancel(), mOnFailureCallback_57.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_57_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_57 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_57_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_57 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16s != 32767)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "32767");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT16S Min Value
    using SuccessCallback_58 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_58> mOnSuccessCallback_58{
        OnTestSendClusterTestClusterCommandWriteAttribute_58_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_58{
        OnTestSendClusterTestClusterCommandWriteAttribute_58_FailureResponse, this
    };
    bool mIsFailureExpected_58 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_58()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int16_t int16sArgument = -32768;
        err = cluster.WriteAttributeInt16s(mOnSuccessCallback_58.Cancel(), mOnFailureCallback_58.Cancel(), int16sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_58_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_58 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_58_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_58 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16S Min Value
    using SuccessCallback_59 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_59> mOnSuccessCallback_59{
        OnTestSendClusterTestClusterCommandReadAttribute_59_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_59{
        OnTestSendClusterTestClusterCommandReadAttribute_59_FailureResponse, this
    };
    bool mIsFailureExpected_59 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_59()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16s(mOnSuccessCallback_59.Cancel(), mOnFailureCallback_59.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_59_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_59 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_59_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_59 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16s != -32768)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "-32768");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT16S Default Value
    using SuccessCallback_60 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_60> mOnSuccessCallback_60{
        OnTestSendClusterTestClusterCommandWriteAttribute_60_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_60{
        OnTestSendClusterTestClusterCommandWriteAttribute_60_FailureResponse, this
    };
    bool mIsFailureExpected_60 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_60()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int16_t int16sArgument = 0;
        err = cluster.WriteAttributeInt16s(mOnSuccessCallback_60.Cancel(), mOnFailureCallback_60.Cancel(), int16sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_60_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_60 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_60_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT16S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_60 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT16S Default Value
    using SuccessCallback_61 = void (*)(void * context, int16_t int16s);
    chip::Callback::Callback<SuccessCallback_61> mOnSuccessCallback_61{
        OnTestSendClusterTestClusterCommandReadAttribute_61_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_61{
        OnTestSendClusterTestClusterCommandReadAttribute_61_FailureResponse, this
    };
    bool mIsFailureExpected_61 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_61()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt16s(mOnSuccessCallback_61.Cancel(), mOnFailureCallback_61.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_61_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_61 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_61_SuccessResponse(void * context, int16_t int16s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT16S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_61 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int16s != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32S Default Value
    using SuccessCallback_62 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_62> mOnSuccessCallback_62{
        OnTestSendClusterTestClusterCommandReadAttribute_62_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_62{
        OnTestSendClusterTestClusterCommandReadAttribute_62_FailureResponse, this
    };
    bool mIsFailureExpected_62 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_62()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32s(mOnSuccessCallback_62.Cancel(), mOnFailureCallback_62.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_62_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_62 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_62_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_62 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32s != 0L)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT32S Max Value
    using SuccessCallback_63 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_63> mOnSuccessCallback_63{
        OnTestSendClusterTestClusterCommandWriteAttribute_63_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_63{
        OnTestSendClusterTestClusterCommandWriteAttribute_63_FailureResponse, this
    };
    bool mIsFailureExpected_63 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_63()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int32_t int32sArgument = 2147483647L;
        err = cluster.WriteAttributeInt32s(mOnSuccessCallback_63.Cancel(), mOnFailureCallback_63.Cancel(), int32sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_63_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_63 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_63_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_63 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32S Max Value
    using SuccessCallback_64 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_64> mOnSuccessCallback_64{
        OnTestSendClusterTestClusterCommandReadAttribute_64_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_64{
        OnTestSendClusterTestClusterCommandReadAttribute_64_FailureResponse, this
    };
    bool mIsFailureExpected_64 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_64()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32s(mOnSuccessCallback_64.Cancel(), mOnFailureCallback_64.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_64_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_64 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_64_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_64 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32s != 2147483647L)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "2147483647");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT32S Min Value
    using SuccessCallback_65 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_65> mOnSuccessCallback_65{
        OnTestSendClusterTestClusterCommandWriteAttribute_65_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_65{
        OnTestSendClusterTestClusterCommandWriteAttribute_65_FailureResponse, this
    };
    bool mIsFailureExpected_65 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_65()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int32_t int32sArgument = -2147483648L;
        err = cluster.WriteAttributeInt32s(mOnSuccessCallback_65.Cancel(), mOnFailureCallback_65.Cancel(), int32sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_65_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_65 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_65_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_65 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32S Min Value
    using SuccessCallback_66 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_66> mOnSuccessCallback_66{
        OnTestSendClusterTestClusterCommandReadAttribute_66_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_66{
        OnTestSendClusterTestClusterCommandReadAttribute_66_FailureResponse, this
    };
    bool mIsFailureExpected_66 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_66()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32s(mOnSuccessCallback_66.Cancel(), mOnFailureCallback_66.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_66_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_66 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_66_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_66 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32s != -2147483648L)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "-2147483648");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT32S Default Value
    using SuccessCallback_67 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_67> mOnSuccessCallback_67{
        OnTestSendClusterTestClusterCommandWriteAttribute_67_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_67{
        OnTestSendClusterTestClusterCommandWriteAttribute_67_FailureResponse, this
    };
    bool mIsFailureExpected_67 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_67()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int32_t int32sArgument = 0L;
        err = cluster.WriteAttributeInt32s(mOnSuccessCallback_67.Cancel(), mOnFailureCallback_67.Cancel(), int32sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_67_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_67 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_67_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT32S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_67 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT32S Default Value
    using SuccessCallback_68 = void (*)(void * context, int32_t int32s);
    chip::Callback::Callback<SuccessCallback_68> mOnSuccessCallback_68{
        OnTestSendClusterTestClusterCommandReadAttribute_68_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_68{
        OnTestSendClusterTestClusterCommandReadAttribute_68_FailureResponse, this
    };
    bool mIsFailureExpected_68 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_68()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt32s(mOnSuccessCallback_68.Cancel(), mOnFailureCallback_68.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_68_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_68 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_68_SuccessResponse(void * context, int32_t int32s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT32S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_68 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int32s != 0L)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64S Default Value
    using SuccessCallback_69 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_69> mOnSuccessCallback_69{
        OnTestSendClusterTestClusterCommandReadAttribute_69_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_69{
        OnTestSendClusterTestClusterCommandReadAttribute_69_FailureResponse, this
    };
    bool mIsFailureExpected_69 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_69()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64s(mOnSuccessCallback_69.Cancel(), mOnFailureCallback_69.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_69_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_69 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_69_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_69 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64s != 0LL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT64S Max Value
    using SuccessCallback_70 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_70> mOnSuccessCallback_70{
        OnTestSendClusterTestClusterCommandWriteAttribute_70_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_70{
        OnTestSendClusterTestClusterCommandWriteAttribute_70_FailureResponse, this
    };
    bool mIsFailureExpected_70 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_70()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int64_t int64sArgument = 9223372036854775807LL;
        err = cluster.WriteAttributeInt64s(mOnSuccessCallback_70.Cancel(), mOnFailureCallback_70.Cancel(), int64sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_70_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_70 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_70_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_70 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64S Max Value
    using SuccessCallback_71 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_71> mOnSuccessCallback_71{
        OnTestSendClusterTestClusterCommandReadAttribute_71_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_71{
        OnTestSendClusterTestClusterCommandReadAttribute_71_FailureResponse, this
    };
    bool mIsFailureExpected_71 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_71()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64s(mOnSuccessCallback_71.Cancel(), mOnFailureCallback_71.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_71_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_71 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_71_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_71 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64s != 9223372036854775807LL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "9223372036854775807");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT64S Min Value
    using SuccessCallback_72 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_72> mOnSuccessCallback_72{
        OnTestSendClusterTestClusterCommandWriteAttribute_72_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_72{
        OnTestSendClusterTestClusterCommandWriteAttribute_72_FailureResponse, this
    };
    bool mIsFailureExpected_72 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_72()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int64_t int64sArgument = -9223372036854775807LL;
        err = cluster.WriteAttributeInt64s(mOnSuccessCallback_72.Cancel(), mOnFailureCallback_72.Cancel(), int64sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_72_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_72 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_72_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_72 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64S Min Value
    using SuccessCallback_73 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_73> mOnSuccessCallback_73{
        OnTestSendClusterTestClusterCommandReadAttribute_73_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_73{
        OnTestSendClusterTestClusterCommandReadAttribute_73_FailureResponse, this
    };
    bool mIsFailureExpected_73 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_73()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64s(mOnSuccessCallback_73.Cancel(), mOnFailureCallback_73.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_73_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_73 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_73_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_73 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64s != -9223372036854775807LL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "-9223372036854775807");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute INT64S Default Value
    using SuccessCallback_74 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_74> mOnSuccessCallback_74{
        OnTestSendClusterTestClusterCommandWriteAttribute_74_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_74{
        OnTestSendClusterTestClusterCommandWriteAttribute_74_FailureResponse, this
    };
    bool mIsFailureExpected_74 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_74()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int64_t int64sArgument = 0LL;
        err = cluster.WriteAttributeInt64s(mOnSuccessCallback_74.Cancel(), mOnFailureCallback_74.Cancel(), int64sArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_74_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_74 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_74_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute INT64S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_74 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute INT64S Default Value
    using SuccessCallback_75 = void (*)(void * context, int64_t int64s);
    chip::Callback::Callback<SuccessCallback_75> mOnSuccessCallback_75{
        OnTestSendClusterTestClusterCommandReadAttribute_75_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_75{
        OnTestSendClusterTestClusterCommandReadAttribute_75_FailureResponse, this
    };
    bool mIsFailureExpected_75 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_75()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInt64s(mOnSuccessCallback_75.Cancel(), mOnFailureCallback_75.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_75_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_75 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_75_SuccessResponse(void * context, int64_t int64s)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute INT64S Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_75 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (int64s != 0LL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute ENUM8 Default Value
    using SuccessCallback_76 = void (*)(void * context, uint8_t enum8);
    chip::Callback::Callback<SuccessCallback_76> mOnSuccessCallback_76{
        OnTestSendClusterTestClusterCommandReadAttribute_76_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_76{
        OnTestSendClusterTestClusterCommandReadAttribute_76_FailureResponse, this
    };
    bool mIsFailureExpected_76 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_76()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnum8(mOnSuccessCallback_76.Cancel(), mOnFailureCallback_76.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_76_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_76 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_76_SuccessResponse(void * context, uint8_t enum8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_76 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (enum8 != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute ENUM8 Max Value
    using SuccessCallback_77 = void (*)(void * context, uint8_t enum8);
    chip::Callback::Callback<SuccessCallback_77> mOnSuccessCallback_77{
        OnTestSendClusterTestClusterCommandWriteAttribute_77_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_77{
        OnTestSendClusterTestClusterCommandWriteAttribute_77_FailureResponse, this
    };
    bool mIsFailureExpected_77 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_77()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM8 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t enum8Argument = 255;
        err = cluster.WriteAttributeEnum8(mOnSuccessCallback_77.Cancel(), mOnFailureCallback_77.Cancel(), enum8Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_77_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM8 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_77 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_77_SuccessResponse(void * context, uint8_t enum8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM8 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_77 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute ENUM8 Max Value
    using SuccessCallback_78 = void (*)(void * context, uint8_t enum8);
    chip::Callback::Callback<SuccessCallback_78> mOnSuccessCallback_78{
        OnTestSendClusterTestClusterCommandReadAttribute_78_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_78{
        OnTestSendClusterTestClusterCommandReadAttribute_78_FailureResponse, this
    };
    bool mIsFailureExpected_78 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_78()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnum8(mOnSuccessCallback_78.Cancel(), mOnFailureCallback_78.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_78_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_78 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_78_SuccessResponse(void * context, uint8_t enum8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_78 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (enum8 != 255)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "255");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute ENUM8 Min Value
    using SuccessCallback_79 = void (*)(void * context, uint8_t enum8);
    chip::Callback::Callback<SuccessCallback_79> mOnSuccessCallback_79{
        OnTestSendClusterTestClusterCommandWriteAttribute_79_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_79{
        OnTestSendClusterTestClusterCommandWriteAttribute_79_FailureResponse, this
    };
    bool mIsFailureExpected_79 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_79()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM8 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t enum8Argument = 0;
        err = cluster.WriteAttributeEnum8(mOnSuccessCallback_79.Cancel(), mOnFailureCallback_79.Cancel(), enum8Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_79_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM8 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_79 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_79_SuccessResponse(void * context, uint8_t enum8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM8 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_79 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute ENUM8 Min Value
    using SuccessCallback_80 = void (*)(void * context, uint8_t enum8);
    chip::Callback::Callback<SuccessCallback_80> mOnSuccessCallback_80{
        OnTestSendClusterTestClusterCommandReadAttribute_80_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_80{
        OnTestSendClusterTestClusterCommandReadAttribute_80_FailureResponse, this
    };
    bool mIsFailureExpected_80 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_80()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnum8(mOnSuccessCallback_80.Cancel(), mOnFailureCallback_80.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_80_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_80 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_80_SuccessResponse(void * context, uint8_t enum8)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM8 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_80 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (enum8 != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute ENUM16 Default Value
    using SuccessCallback_81 = void (*)(void * context, uint16_t enum16);
    chip::Callback::Callback<SuccessCallback_81> mOnSuccessCallback_81{
        OnTestSendClusterTestClusterCommandReadAttribute_81_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_81{
        OnTestSendClusterTestClusterCommandReadAttribute_81_FailureResponse, this
    };
    bool mIsFailureExpected_81 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_81()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnum16(mOnSuccessCallback_81.Cancel(), mOnFailureCallback_81.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_81_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_81 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_81_SuccessResponse(void * context, uint16_t enum16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_81 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (enum16 != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute ENUM16 Max Value
    using SuccessCallback_82 = void (*)(void * context, uint16_t enum16);
    chip::Callback::Callback<SuccessCallback_82> mOnSuccessCallback_82{
        OnTestSendClusterTestClusterCommandWriteAttribute_82_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_82{
        OnTestSendClusterTestClusterCommandWriteAttribute_82_FailureResponse, this
    };
    bool mIsFailureExpected_82 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_82()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM16 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t enum16Argument = 65535U;
        err = cluster.WriteAttributeEnum16(mOnSuccessCallback_82.Cancel(), mOnFailureCallback_82.Cancel(), enum16Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_82_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM16 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_82 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_82_SuccessResponse(void * context, uint16_t enum16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM16 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_82 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute ENUM16 Max Value
    using SuccessCallback_83 = void (*)(void * context, uint16_t enum16);
    chip::Callback::Callback<SuccessCallback_83> mOnSuccessCallback_83{
        OnTestSendClusterTestClusterCommandReadAttribute_83_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_83{
        OnTestSendClusterTestClusterCommandReadAttribute_83_FailureResponse, this
    };
    bool mIsFailureExpected_83 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_83()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Max Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnum16(mOnSuccessCallback_83.Cancel(), mOnFailureCallback_83.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_83_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Max Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_83 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_83_SuccessResponse(void * context, uint16_t enum16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Max Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_83 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (enum16 != 65535U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "65535");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute ENUM16 Min Value
    using SuccessCallback_84 = void (*)(void * context, uint16_t enum16);
    chip::Callback::Callback<SuccessCallback_84> mOnSuccessCallback_84{
        OnTestSendClusterTestClusterCommandWriteAttribute_84_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_84{
        OnTestSendClusterTestClusterCommandWriteAttribute_84_FailureResponse, this
    };
    bool mIsFailureExpected_84 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_84()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM16 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t enum16Argument = 0U;
        err = cluster.WriteAttributeEnum16(mOnSuccessCallback_84.Cancel(), mOnFailureCallback_84.Cancel(), enum16Argument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_84_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM16 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_84 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_84_SuccessResponse(void * context, uint16_t enum16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute ENUM16 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_84 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute ENUM16 Min Value
    using SuccessCallback_85 = void (*)(void * context, uint16_t enum16);
    chip::Callback::Callback<SuccessCallback_85> mOnSuccessCallback_85{
        OnTestSendClusterTestClusterCommandReadAttribute_85_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_85{
        OnTestSendClusterTestClusterCommandReadAttribute_85_FailureResponse, this
    };
    bool mIsFailureExpected_85 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_85()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Min Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnum16(mOnSuccessCallback_85.Cancel(), mOnFailureCallback_85.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_85_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Min Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_85 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_85_SuccessResponse(void * context, uint16_t enum16)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute ENUM16 Min Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_85 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (enum16 != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute OCTET_STRING Default Value
    using SuccessCallback_86 = void (*)(void * context, chip::ByteSpan octetString);
    chip::Callback::Callback<SuccessCallback_86> mOnSuccessCallback_86{
        OnTestSendClusterTestClusterCommandReadAttribute_86_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_86{
        OnTestSendClusterTestClusterCommandReadAttribute_86_FailureResponse, this
    };
    bool mIsFailureExpected_86 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_86()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOctetString(mOnSuccessCallback_86.Cancel(), mOnFailureCallback_86.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_86_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_86 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_86_SuccessResponse(void * context, chip::ByteSpan octetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_86 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan octetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        if (!octetString.data_equal(octetStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute OCTET_STRING
    using SuccessCallback_87 = void (*)(void * context, chip::ByteSpan octetString);
    chip::Callback::Callback<SuccessCallback_87> mOnSuccessCallback_87{
        OnTestSendClusterTestClusterCommandWriteAttribute_87_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_87{
        OnTestSendClusterTestClusterCommandWriteAttribute_87_FailureResponse, this
    };
    bool mIsFailureExpected_87 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_87()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan octetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char("TestValue"), strlen("TestValue"));
        err =
            cluster.WriteAttributeOctetString(mOnSuccessCallback_87.Cancel(), mOnFailureCallback_87.Cancel(), octetStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_87_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_87 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_87_SuccessResponse(void * context, chip::ByteSpan octetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_87 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute OCTET_STRING
    using SuccessCallback_88 = void (*)(void * context, chip::ByteSpan octetString);
    chip::Callback::Callback<SuccessCallback_88> mOnSuccessCallback_88{
        OnTestSendClusterTestClusterCommandReadAttribute_88_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_88{
        OnTestSendClusterTestClusterCommandReadAttribute_88_FailureResponse, this
    };
    bool mIsFailureExpected_88 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_88()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOctetString(mOnSuccessCallback_88.Cancel(), mOnFailureCallback_88.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_88_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_88 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_88_SuccessResponse(void * context, chip::ByteSpan octetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_88 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan octetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char("TestValue"), strlen("TestValue"));
        if (!octetString.data_equal(octetStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "TestValue");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute OCTET_STRING
    using SuccessCallback_89 = void (*)(void * context, chip::ByteSpan octetString);
    chip::Callback::Callback<SuccessCallback_89> mOnSuccessCallback_89{
        OnTestSendClusterTestClusterCommandWriteAttribute_89_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_89{
        OnTestSendClusterTestClusterCommandWriteAttribute_89_FailureResponse, this
    };
    bool mIsFailureExpected_89 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_89()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan octetStringArgument =
            chip::ByteSpan(chip::Uint8::from_const_char("TestValueLongerThan10"), strlen("TestValueLongerThan10"));
        err =
            cluster.WriteAttributeOctetString(mOnSuccessCallback_89.Cancel(), mOnFailureCallback_89.Cancel(), octetStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_89_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_89 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_89_SuccessResponse(void * context, chip::ByteSpan octetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_89 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute OCTET_STRING
    using SuccessCallback_90 = void (*)(void * context, chip::ByteSpan octetString);
    chip::Callback::Callback<SuccessCallback_90> mOnSuccessCallback_90{
        OnTestSendClusterTestClusterCommandReadAttribute_90_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_90{
        OnTestSendClusterTestClusterCommandReadAttribute_90_FailureResponse, this
    };
    bool mIsFailureExpected_90 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_90()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOctetString(mOnSuccessCallback_90.Cancel(), mOnFailureCallback_90.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_90_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_90 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_90_SuccessResponse(void * context, chip::ByteSpan octetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_90 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan octetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char("TestValue"), strlen("TestValue"));
        if (!octetString.data_equal(octetStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "TestValue");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute OCTET_STRING
    using SuccessCallback_91 = void (*)(void * context, chip::ByteSpan octetString);
    chip::Callback::Callback<SuccessCallback_91> mOnSuccessCallback_91{
        OnTestSendClusterTestClusterCommandWriteAttribute_91_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_91{
        OnTestSendClusterTestClusterCommandWriteAttribute_91_FailureResponse, this
    };
    bool mIsFailureExpected_91 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_91()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan octetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        err =
            cluster.WriteAttributeOctetString(mOnSuccessCallback_91.Cancel(), mOnFailureCallback_91.Cancel(), octetStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_91_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_91 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_91_SuccessResponse(void * context, chip::ByteSpan octetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_91 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LONG_OCTET_STRING Default Value
    using SuccessCallback_92 = void (*)(void * context, chip::ByteSpan longOctetString);
    chip::Callback::Callback<SuccessCallback_92> mOnSuccessCallback_92{
        OnTestSendClusterTestClusterCommandReadAttribute_92_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_92{
        OnTestSendClusterTestClusterCommandReadAttribute_92_FailureResponse, this
    };
    bool mIsFailureExpected_92 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_92()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_OCTET_STRING Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeLongOctetString(mOnSuccessCallback_92.Cancel(), mOnFailureCallback_92.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_92_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_OCTET_STRING Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_92 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_92_SuccessResponse(void * context, chip::ByteSpan longOctetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_OCTET_STRING Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_92 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan longOctetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        if (!longOctetString.data_equal(longOctetStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute LONG_OCTET_STRING
    using SuccessCallback_93 = void (*)(void * context, chip::ByteSpan longOctetString);
    chip::Callback::Callback<SuccessCallback_93> mOnSuccessCallback_93{
        OnTestSendClusterTestClusterCommandWriteAttribute_93_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_93{
        OnTestSendClusterTestClusterCommandWriteAttribute_93_FailureResponse, this
    };
    bool mIsFailureExpected_93 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_93()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan longOctetStringArgument = chip::ByteSpan(
            chip::Uint8::from_const_char(
                "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                "111111111111111111111111111111111111111111111111111111111111111111111111"),
            strlen("111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                   "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                   "111111111111111111111111111111111111111111111111111111111111111111111111111111"));
        err = cluster.WriteAttributeLongOctetString(mOnSuccessCallback_93.Cancel(), mOnFailureCallback_93.Cancel(),
                                                    longOctetStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_93_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_93 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_93_SuccessResponse(void * context, chip::ByteSpan longOctetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_93 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LONG_OCTET_STRING
    using SuccessCallback_94 = void (*)(void * context, chip::ByteSpan longOctetString);
    chip::Callback::Callback<SuccessCallback_94> mOnSuccessCallback_94{
        OnTestSendClusterTestClusterCommandReadAttribute_94_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_94{
        OnTestSendClusterTestClusterCommandReadAttribute_94_FailureResponse, this
    };
    bool mIsFailureExpected_94 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_94()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeLongOctetString(mOnSuccessCallback_94.Cancel(), mOnFailureCallback_94.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_94_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_94 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_94_SuccessResponse(void * context, chip::ByteSpan longOctetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_94 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan longOctetStringArgument = chip::ByteSpan(
            chip::Uint8::from_const_char(
                "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                "111111111111111111111111111111111111111111111111111111111111111111111111"),
            strlen("111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                   "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                   "111111111111111111111111111111111111111111111111111111111111111111111111111111"));
        if (!longOctetString.data_equal(longOctetStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'",
                         "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                         "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111"
                         "111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute LONG_OCTET_STRING
    using SuccessCallback_95 = void (*)(void * context, chip::ByteSpan longOctetString);
    chip::Callback::Callback<SuccessCallback_95> mOnSuccessCallback_95{
        OnTestSendClusterTestClusterCommandWriteAttribute_95_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_95{
        OnTestSendClusterTestClusterCommandWriteAttribute_95_FailureResponse, this
    };
    bool mIsFailureExpected_95 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_95()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan longOctetStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        err = cluster.WriteAttributeLongOctetString(mOnSuccessCallback_95.Cancel(), mOnFailureCallback_95.Cancel(),
                                                    longOctetStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_95_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_95 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_95_SuccessResponse(void * context, chip::ByteSpan longOctetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_95 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute CHAR_STRING Default Value
    using SuccessCallback_96 = void (*)(void * context, chip::ByteSpan charString);
    chip::Callback::Callback<SuccessCallback_96> mOnSuccessCallback_96{
        OnTestSendClusterTestClusterCommandReadAttribute_96_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_96{
        OnTestSendClusterTestClusterCommandReadAttribute_96_FailureResponse, this
    };
    bool mIsFailureExpected_96 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_96()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute CHAR_STRING Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCharString(mOnSuccessCallback_96.Cancel(), mOnFailureCallback_96.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_96_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute CHAR_STRING Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_96 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_96_SuccessResponse(void * context, chip::ByteSpan charString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute CHAR_STRING Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_96 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan charStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        if (!charString.data_equal(charStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute CHAR_STRING
    using SuccessCallback_97 = void (*)(void * context, chip::ByteSpan charString);
    chip::Callback::Callback<SuccessCallback_97> mOnSuccessCallback_97{
        OnTestSendClusterTestClusterCommandWriteAttribute_97_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_97{
        OnTestSendClusterTestClusterCommandWriteAttribute_97_FailureResponse, this
    };
    bool mIsFailureExpected_97 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_97()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan charStringArgument = chip::ByteSpan(chip::Uint8::from_const_char("☉Test☉"), strlen("☉Test☉"));
        err = cluster.WriteAttributeCharString(mOnSuccessCallback_97.Cancel(), mOnFailureCallback_97.Cancel(), charStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_97_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_97 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_97_SuccessResponse(void * context, chip::ByteSpan charString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_97 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute CHAR_STRING
    using SuccessCallback_98 = void (*)(void * context, chip::ByteSpan charString);
    chip::Callback::Callback<SuccessCallback_98> mOnSuccessCallback_98{
        OnTestSendClusterTestClusterCommandWriteAttribute_98_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_98{
        OnTestSendClusterTestClusterCommandWriteAttribute_98_FailureResponse, this
    };
    bool mIsFailureExpected_98 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_98()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan charStringArgument =
            chip::ByteSpan(chip::Uint8::from_const_char("☉TestValueLongerThan10☉"), strlen("☉TestValueLongerThan10☉"));
        err = cluster.WriteAttributeCharString(mOnSuccessCallback_98.Cancel(), mOnFailureCallback_98.Cancel(), charStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_98_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_98 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_98_SuccessResponse(void * context, chip::ByteSpan charString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_98 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute CHAR_STRING
    using SuccessCallback_99 = void (*)(void * context, chip::ByteSpan charString);
    chip::Callback::Callback<SuccessCallback_99> mOnSuccessCallback_99{
        OnTestSendClusterTestClusterCommandWriteAttribute_99_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_99{
        OnTestSendClusterTestClusterCommandWriteAttribute_99_FailureResponse, this
    };
    bool mIsFailureExpected_99 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_99()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan charStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        err = cluster.WriteAttributeCharString(mOnSuccessCallback_99.Cancel(), mOnFailureCallback_99.Cancel(), charStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_99_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_99 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_99_SuccessResponse(void * context, chip::ByteSpan charString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute CHAR_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_99 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LONG_CHAR_STRING Default Value
    using SuccessCallback_100 = void (*)(void * context, chip::ByteSpan longCharString);
    chip::Callback::Callback<SuccessCallback_100> mOnSuccessCallback_100{
        OnTestSendClusterTestClusterCommandReadAttribute_100_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_100{
        OnTestSendClusterTestClusterCommandReadAttribute_100_FailureResponse, this
    };
    bool mIsFailureExpected_100 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_100()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_CHAR_STRING Default Value: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeLongCharString(mOnSuccessCallback_100.Cancel(), mOnFailureCallback_100.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_100_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_CHAR_STRING Default Value: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_100 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_100_SuccessResponse(void * context, chip::ByteSpan longCharString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_CHAR_STRING Default Value: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_100 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan longCharStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        if (!longCharString.data_equal(longCharStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute LONG_CHAR_STRING
    using SuccessCallback_101 = void (*)(void * context, chip::ByteSpan longCharString);
    chip::Callback::Callback<SuccessCallback_101> mOnSuccessCallback_101{
        OnTestSendClusterTestClusterCommandWriteAttribute_101_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_101{
        OnTestSendClusterTestClusterCommandWriteAttribute_101_FailureResponse, this
    };
    bool mIsFailureExpected_101 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_101()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_CHAR_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan longCharStringArgument = chip::ByteSpan(
            chip::Uint8::from_const_char(
                "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"),
            strlen("☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                   "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                   "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"));
        err = cluster.WriteAttributeLongCharString(mOnSuccessCallback_101.Cancel(), mOnFailureCallback_101.Cancel(),
                                                   longCharStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_101_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_CHAR_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_101 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_101_SuccessResponse(void * context, chip::ByteSpan longCharString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_CHAR_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_101 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LONG_CHAR_STRING
    using SuccessCallback_102 = void (*)(void * context, chip::ByteSpan longCharString);
    chip::Callback::Callback<SuccessCallback_102> mOnSuccessCallback_102{
        OnTestSendClusterTestClusterCommandReadAttribute_102_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_102{
        OnTestSendClusterTestClusterCommandReadAttribute_102_FailureResponse, this
    };
    bool mIsFailureExpected_102 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_102()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_CHAR_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeLongCharString(mOnSuccessCallback_102.Cancel(), mOnFailureCallback_102.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_102_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_CHAR_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_102 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_102_SuccessResponse(void * context, chip::ByteSpan longCharString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LONG_CHAR_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_102 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        chip::ByteSpan longCharStringArgument = chip::ByteSpan(
            chip::Uint8::from_const_char(
                "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"),
            strlen("☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                   "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                   "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"));
        if (!longCharString.data_equal(longCharStringArgument))
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'",
                         "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                         "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉"
                         "☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉☉");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Write attribute LONG_CHAR_STRING
    using SuccessCallback_103 = void (*)(void * context, chip::ByteSpan longCharString);
    chip::Callback::Callback<SuccessCallback_103> mOnSuccessCallback_103{
        OnTestSendClusterTestClusterCommandWriteAttribute_103_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_103{
        OnTestSendClusterTestClusterCommandWriteAttribute_103_FailureResponse, this
    };
    bool mIsFailureExpected_103 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_103()
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_CHAR_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        chip::ByteSpan longCharStringArgument = chip::ByteSpan(chip::Uint8::from_const_char(""), strlen(""));
        err = cluster.WriteAttributeLongCharString(mOnSuccessCallback_103.Cancel(), mOnFailureCallback_103.Cancel(),
                                                   longCharStringArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_103_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_CHAR_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_103 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_103_SuccessResponse(void * context, chip::ByteSpan longCharString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Write attribute LONG_CHAR_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_103 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LIST
    using SuccessCallback_104 = void (*)(void * context, uint16_t count, uint8_t * listInt8u);
    chip::Callback::Callback<SuccessCallback_104> mOnSuccessCallback_104{
        OnTestSendClusterTestClusterCommandReadAttribute_104_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_104{
        OnTestSendClusterTestClusterCommandReadAttribute_104_FailureResponse, this
    };
    bool mIsFailureExpected_104 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_104()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeListInt8u(mOnSuccessCallback_104.Cancel(), mOnFailureCallback_104.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_104_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_104 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_104_SuccessResponse(void * context, uint16_t count,
                                                                                     uint8_t * listInt8u)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_104 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 4)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1,2,3,4");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LIST_OCTET_STRING
    using SuccessCallback_105 = void (*)(void * context, uint16_t count, chip::ByteSpan * listOctetString);
    chip::Callback::Callback<SuccessCallback_105> mOnSuccessCallback_105{
        OnTestSendClusterTestClusterCommandReadAttribute_105_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_105{
        OnTestSendClusterTestClusterCommandReadAttribute_105_FailureResponse, this
    };
    bool mIsFailureExpected_105 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_105()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST_OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeListOctetString(mOnSuccessCallback_105.Cancel(), mOnFailureCallback_105.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_105_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST_OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_105 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_105_SuccessResponse(void * context, uint16_t count,
                                                                                     chip::ByteSpan * listOctetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST_OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_105 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 4)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "Test0,Test1,Test2,Test3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute LIST_STRUCT_OCTET_STRING
    using SuccessCallback_106 = void (*)(void * context, uint16_t count, _TestListStructOctet * listStructOctetString);
    chip::Callback::Callback<SuccessCallback_106> mOnSuccessCallback_106{
        OnTestSendClusterTestClusterCommandReadAttribute_106_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_106{
        OnTestSendClusterTestClusterCommandReadAttribute_106_FailureResponse, this
    };
    bool mIsFailureExpected_106 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_106()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST_STRUCT_OCTET_STRING: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeListStructOctetString(mOnSuccessCallback_106.Cancel(), mOnFailureCallback_106.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_106_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST_STRUCT_OCTET_STRING: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_106 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_106_SuccessResponse(void * context, uint16_t count,
                                                                                     _TestListStructOctet * listStructOctetString)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute LIST_STRUCT_OCTET_STRING: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_106 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (count != 4)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'",
                         "[object Object],[object Object],[object Object],[object Object]");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read attribute UNSUPPORTED
    using SuccessCallback_107 = void (*)(void * context, uint8_t unsupported);
    chip::Callback::Callback<SuccessCallback_107> mOnSuccessCallback_107{
        OnTestSendClusterTestClusterCommandReadAttribute_107_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_107{
        OnTestSendClusterTestClusterCommandReadAttribute_107_FailureResponse, this
    };
    bool mIsFailureExpected_107 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandReadAttribute_107()
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute UNSUPPORTED: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeUnsupported(mOnSuccessCallback_107.Cancel(), mOnFailureCallback_107.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_107_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute UNSUPPORTED: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_107 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandReadAttribute_107_SuccessResponse(void * context, uint8_t unsupported)
    {
        ChipLogProgress(chipTool, "Test Cluster - Read attribute UNSUPPORTED: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_107 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (unsupported != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Writeattribute UNSUPPORTED
    using SuccessCallback_108 = void (*)(void * context, uint8_t unsupported);
    chip::Callback::Callback<SuccessCallback_108> mOnSuccessCallback_108{
        OnTestSendClusterTestClusterCommandWriteAttribute_108_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_108{
        OnTestSendClusterTestClusterCommandWriteAttribute_108_FailureResponse, this
    };
    bool mIsFailureExpected_108 = 0;

    CHIP_ERROR TestSendClusterTestClusterCommandWriteAttribute_108()
    {
        ChipLogProgress(chipTool, "Test Cluster - Writeattribute UNSUPPORTED: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t unsupportedArgument = 0;
        err = cluster.WriteAttributeUnsupported(mOnSuccessCallback_108.Cancel(), mOnFailureCallback_108.Cancel(),
                                                unsupportedArgument);

        return err;
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_108_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Writeattribute UNSUPPORTED: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_108 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandWriteAttribute_108_SuccessResponse(void * context, uint8_t unsupported)
    {
        ChipLogProgress(chipTool, "Test Cluster - Writeattribute UNSUPPORTED: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_108 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Test Command to unsupported endpoint
    using SuccessCallback_109 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_109> mOnSuccessCallback_109{
        OnTestSendClusterTestClusterCommandTest_109_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_109{
        OnTestSendClusterTestClusterCommandTest_109_FailureResponse, this
    };
    bool mIsFailureExpected_109 = 1;

    CHIP_ERROR TestSendClusterTestClusterCommandTest_109()
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Command to unsupported endpoint: Sending command...");

        chip::Controller::TestClusterCluster cluster;
        cluster.Associate(mDevice, 200);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Test(mOnSuccessCallback_109.Cancel(), mOnFailureCallback_109.Cancel());

        return err;
    }

    static void OnTestSendClusterTestClusterCommandTest_109_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Command to unsupported endpoint: Failure Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_109 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterTestClusterCommandTest_109_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Test Cluster - Send Test Command to unsupported endpoint: Success Response");

        TestCluster * runner = reinterpret_cast<TestCluster *>(context);

        if (runner->mIsFailureExpected_109 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_OO_1_1 : public TestCommand
{
public:
    Test_TC_OO_1_1() : TestCommand("Test_TC_OO_1_1"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_OO_1_1: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterOnOffCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterOnOffCommandReadAttribute_3();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_OO_1_1: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 4;

    //
    // Tests methods
    //

    // Test read the global attribute: ClusterRevision
    using SuccessCallback_0 = void (*)(void * context, uint16_t clusterRevision);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandReadAttribute_0_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterOnOffCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "On/Off - read the global attribute: ClusterRevision: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeClusterRevision(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read the global attribute: ClusterRevision: Failure Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_0_SuccessResponse(void * context, uint16_t clusterRevision)
    {
        ChipLogProgress(chipTool, "On/Off - read the global attribute: ClusterRevision: Success Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (clusterRevision != 3U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back global attribute: ClusterRevision
    using SuccessCallback_1 = void (*)(void * context, uint16_t clusterRevision);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - reads back global attribute: ClusterRevision: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeClusterRevision(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - reads back global attribute: ClusterRevision: Failure Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint16_t clusterRevision)
    {
        ChipLogProgress(chipTool, "On/Off - reads back global attribute: ClusterRevision: Success Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (clusterRevision != 3U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read the optional global attribute: FeatureMap
    using SuccessCallback_2 = void (*)(void * context, uint32_t featureMap);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{ OnTestSendClusterOnOffCommandReadAttribute_2_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterOnOffCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "On/Off - read the optional global attribute: FeatureMap: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeFeatureMap(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read the optional global attribute: FeatureMap: Failure Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_2_SuccessResponse(void * context, uint32_t featureMap)
    {
        ChipLogProgress(chipTool, "On/Off - read the optional global attribute: FeatureMap: Success Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (featureMap != 0UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back optional global attribute: FeatureMap
    using SuccessCallback_3 = void (*)(void * context, uint32_t featureMap);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{ OnTestSendClusterOnOffCommandReadAttribute_3_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterOnOffCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "On/Off - reads back optional global attribute: FeatureMap: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeFeatureMap(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - reads back optional global attribute: FeatureMap: Failure Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_3_SuccessResponse(void * context, uint32_t featureMap)
    {
        ChipLogProgress(chipTool, "On/Off - reads back optional global attribute: FeatureMap: Success Response");

        Test_TC_OO_1_1 * runner = reinterpret_cast<Test_TC_OO_1_1 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (featureMap != 0UL)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_OO_2_1 : public TestCommand
{
public:
    Test_TC_OO_2_1() : TestCommand("Test_TC_OO_2_1"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_OO_2_1: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterOnOffCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterOnOffCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterOnOffCommandReadAttribute_4();
            break;
        case 5:
            err = TestSendClusterOnOffCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterOnOffCommandWriteAttribute_6();
            break;
        case 7:
            err = TestSendClusterOnOffCommandWriteAttribute_7();
            break;
        case 8:
            err = TestSendClusterOnOffCommandWriteAttribute_8();
            break;
        case 9:
            err = TestSendClusterOnOffCommandReadAttribute_9();
            break;
        case 10:
            err = TestSendClusterOnOffCommandReadAttribute_10();
            break;
        case 11:
            err = TestSendClusterOnOffCommandReadAttribute_11();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_OO_2_1: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 12;

    //
    // Tests methods
    //

    // Test read the mandatory attribute: OnOff
    using SuccessCallback_0 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandReadAttribute_0_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterOnOffCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "On/Off - read the mandatory attribute: OnOff: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read the mandatory attribute: OnOff: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_0_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - read the mandatory attribute: OnOff: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back mandatory attribute: OnOff
    using SuccessCallback_1 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - reads back mandatory attribute: OnOff: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - reads back mandatory attribute: OnOff: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - reads back mandatory attribute: OnOff: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read LT attribute: GlobalSceneControl
    using SuccessCallback_2 = void (*)(void * context, uint8_t globalSceneControl);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{ OnTestSendClusterOnOffCommandReadAttribute_2_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterOnOffCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: GlobalSceneControl: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeGlobalSceneControl(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: GlobalSceneControl: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_2_SuccessResponse(void * context, uint8_t globalSceneControl)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: GlobalSceneControl: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (globalSceneControl != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read LT attribute: OnTime
    using SuccessCallback_3 = void (*)(void * context, uint16_t onTime);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{ OnTestSendClusterOnOffCommandReadAttribute_3_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterOnOffCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: OnTime: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnTime(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: OnTime: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_3_SuccessResponse(void * context, uint16_t onTime)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: OnTime: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onTime != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read LT attribute: OffWaitTime
    using SuccessCallback_4 = void (*)(void * context, uint16_t offWaitTime);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{ OnTestSendClusterOnOffCommandReadAttribute_4_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterOnOffCommandReadAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_4()
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: OffWaitTime: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOffWaitTime(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: OffWaitTime: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_4_SuccessResponse(void * context, uint16_t offWaitTime)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: OffWaitTime: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (offWaitTime != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read LT attribute: StartUpOnOff
    using SuccessCallback_5 = void (*)(void * context, uint8_t startUpOnOff);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{ OnTestSendClusterOnOffCommandReadAttribute_5_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterOnOffCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: StartUpOnOff: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeStartUpOnOff(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: StartUpOnOff: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_5_SuccessResponse(void * context, uint8_t startUpOnOff)
    {
        ChipLogProgress(chipTool, "On/Off - read LT attribute: StartUpOnOff: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (startUpOnOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test write the default value to LT attribute: OnTime
    using SuccessCallback_6 = void (*)(void * context, uint16_t onTime);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{ OnTestSendClusterOnOffCommandWriteAttribute_6_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterOnOffCommandWriteAttribute_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandWriteAttribute_6()
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: OnTime: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t onTimeArgument = 0U;
        err = cluster.WriteAttributeOnTime(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel(), onTimeArgument);

        return err;
    }

    static void OnTestSendClusterOnOffCommandWriteAttribute_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: OnTime: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandWriteAttribute_6_SuccessResponse(void * context, uint16_t onTime)
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: OnTime: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test write the default value to LT attribute: OffWaitTime
    using SuccessCallback_7 = void (*)(void * context, uint16_t offWaitTime);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{ OnTestSendClusterOnOffCommandWriteAttribute_7_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterOnOffCommandWriteAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandWriteAttribute_7()
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: OffWaitTime: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t offWaitTimeArgument = 0U;
        err = cluster.WriteAttributeOffWaitTime(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel(), offWaitTimeArgument);

        return err;
    }

    static void OnTestSendClusterOnOffCommandWriteAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: OffWaitTime: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandWriteAttribute_7_SuccessResponse(void * context, uint16_t offWaitTime)
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: OffWaitTime: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test write the default value to LT attribute: StartUpOnOff
    using SuccessCallback_8 = void (*)(void * context, uint8_t startUpOnOff);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{ OnTestSendClusterOnOffCommandWriteAttribute_8_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterOnOffCommandWriteAttribute_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandWriteAttribute_8()
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: StartUpOnOff: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t startUpOnOffArgument = 0;
        err =
            cluster.WriteAttributeStartUpOnOff(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel(), startUpOnOffArgument);

        return err;
    }

    static void OnTestSendClusterOnOffCommandWriteAttribute_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: StartUpOnOff: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandWriteAttribute_8_SuccessResponse(void * context, uint8_t startUpOnOff)
    {
        ChipLogProgress(chipTool, "On/Off - write the default value to LT attribute: StartUpOnOff: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back LT attribute: OnTime
    using SuccessCallback_9 = void (*)(void * context, uint16_t onTime);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{ OnTestSendClusterOnOffCommandReadAttribute_9_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterOnOffCommandReadAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_9()
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: OnTime: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnTime(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: OnTime: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_9_SuccessResponse(void * context, uint16_t onTime)
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: OnTime: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onTime != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back LT attribute: OffWaitTime
    using SuccessCallback_10 = void (*)(void * context, uint16_t offWaitTime);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterOnOffCommandReadAttribute_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterOnOffCommandReadAttribute_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_10()
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: OffWaitTime: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOffWaitTime(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: OffWaitTime: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_10_SuccessResponse(void * context, uint16_t offWaitTime)
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: OffWaitTime: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (offWaitTime != 0U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back LT attribute: StartUpOnOff
    using SuccessCallback_11 = void (*)(void * context, uint8_t startUpOnOff);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterOnOffCommandReadAttribute_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterOnOffCommandReadAttribute_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_11()
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: StartUpOnOff: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeStartUpOnOff(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: StartUpOnOff: Failure Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_11_SuccessResponse(void * context, uint8_t startUpOnOff)
    {
        ChipLogProgress(chipTool, "On/Off - reads back LT attribute: StartUpOnOff: Success Response");

        Test_TC_OO_2_1 * runner = reinterpret_cast<Test_TC_OO_2_1 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (startUpOnOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_OO_2_2 : public TestCommand
{
public:
    Test_TC_OO_2_2() : TestCommand("Test_TC_OO_2_2"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_OO_2_2: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandOff_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterOnOffCommandOn_2();
            break;
        case 3:
            err = TestSendClusterOnOffCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterOnOffCommandOff_4();
            break;
        case 5:
            err = TestSendClusterOnOffCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterOnOffCommandToggle_6();
            break;
        case 7:
            err = TestSendClusterOnOffCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterOnOffCommandToggle_8();
            break;
        case 9:
            err = TestSendClusterOnOffCommandReadAttribute_9();
            break;
        case 10:
            err = TestSendClusterOnOffCommandOn_10();
            break;
        case 11:
            err = TestSendClusterOnOffCommandReadAttribute_11();
            break;
        case 12:
            err = TestSendClusterOnOffCommandOff_12();
            break;
        case 13:
            err = TestSendClusterOnOffCommandReadAttribute_13();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_OO_2_2: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 14;

    //
    // Tests methods
    //

    // Test Send Off Command
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandOff_0_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{ OnTestSendClusterOnOffCommandOff_0_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOff_0()
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Off(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOff_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOff_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is false after off command
    using SuccessCallback_1 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send On Command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{ OnTestSendClusterOnOffCommandOn_2_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{ OnTestSendClusterOnOffCommandOn_2_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOn_2()
    {
        ChipLogProgress(chipTool, "On/Off - Send On Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.On(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOn_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send On Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOn_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send On Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after on command
    using SuccessCallback_3 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{ OnTestSendClusterOnOffCommandReadAttribute_3_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterOnOffCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_3_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Off Command
    using SuccessCallback_4 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{ OnTestSendClusterOnOffCommandOff_4_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{ OnTestSendClusterOnOffCommandOff_4_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOff_4()
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Off(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOff_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOff_4_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is false after off command
    using SuccessCallback_5 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{ OnTestSendClusterOnOffCommandReadAttribute_5_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterOnOffCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_5_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Toggle Command
    using SuccessCallback_6 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{ OnTestSendClusterOnOffCommandToggle_6_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{ OnTestSendClusterOnOffCommandToggle_6_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandToggle_6()
    {
        ChipLogProgress(chipTool, "On/Off - Send Toggle Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Toggle(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandToggle_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send Toggle Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandToggle_6_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send Toggle Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after toggle command
    using SuccessCallback_7 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{ OnTestSendClusterOnOffCommandReadAttribute_7_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterOnOffCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_7()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after toggle command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after toggle command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_7_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after toggle command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Toggle Command
    using SuccessCallback_8 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{ OnTestSendClusterOnOffCommandToggle_8_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{ OnTestSendClusterOnOffCommandToggle_8_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandToggle_8()
    {
        ChipLogProgress(chipTool, "On/Off - Send Toggle Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Toggle(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandToggle_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send Toggle Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandToggle_8_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send Toggle Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is false after toggle command
    using SuccessCallback_9 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{ OnTestSendClusterOnOffCommandReadAttribute_9_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterOnOffCommandReadAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_9()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after toggle command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after toggle command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_9_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after toggle command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send On Command
    using SuccessCallback_10 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{ OnTestSendClusterOnOffCommandOn_10_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{ OnTestSendClusterOnOffCommandOn_10_FailureResponse,
                                                                            this };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOn_10()
    {
        ChipLogProgress(chipTool, "On/Off - Send On Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.On(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOn_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send On Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOn_10_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send On Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after on command
    using SuccessCallback_11 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterOnOffCommandReadAttribute_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterOnOffCommandReadAttribute_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_11()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_11_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Send Off Command
    using SuccessCallback_12 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{ OnTestSendClusterOnOffCommandOff_12_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{ OnTestSendClusterOnOffCommandOff_12_FailureResponse,
                                                                            this };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOff_12()
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.Off(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOff_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOff_12_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Send Off Command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is false after off command
    using SuccessCallback_13 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterOnOffCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterOnOffCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_13()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Failure Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_13_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is false after off command: Success Response");

        Test_TC_OO_2_2 * runner = reinterpret_cast<Test_TC_OO_2_2 *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_DM_1_1 : public TestCommand
{
public:
    Test_TC_DM_1_1() : TestCommand("Test_TC_DM_1_1"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_DM_1_1: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterBasicCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterBasicCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterBasicCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterBasicCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterBasicCommandReadAttribute_4();
            break;
        case 5:
            err = TestSendClusterBasicCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterBasicCommandReadAttribute_6();
            break;
        case 7:
            err = TestSendClusterBasicCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterBasicCommandReadAttribute_8();
            break;
        case 9:
            err = TestSendClusterBasicCommandReadAttribute_9();
            break;
        case 10:
            err = TestSendClusterBasicCommandReadAttribute_10();
            break;
        case 11:
            err = TestSendClusterBasicCommandReadAttribute_11();
            break;
        case 12:
            err = TestSendClusterBasicCommandReadAttribute_12();
            break;
        case 13:
            err = TestSendClusterBasicCommandReadAttribute_13();
            break;
        case 14:
            err = TestSendClusterBasicCommandReadAttribute_14();
            break;
        case 15:
            err = TestSendClusterBasicCommandReadAttribute_15();
            break;
        case 16:
            err = TestSendClusterBasicCommandReadAttribute_16();
            break;
        case 17:
            err = TestSendClusterBasicCommandReadAttribute_17();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_DM_1_1: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 18;

    //
    // Tests methods
    //

    // Test Query Interaction Model Version
    using SuccessCallback_0 = void (*)(void * context, uint16_t interactionModelVersion);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterBasicCommandReadAttribute_0_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterBasicCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Basic - Query Interaction Model Version: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeInteractionModelVersion(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query Interaction Model Version: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_0_SuccessResponse(void * context, uint16_t interactionModelVersion)
    {
        ChipLogProgress(chipTool, "Basic - Query Interaction Model Version: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: interactionModelVersion type checking is not implemented yet. Expected type: '%s'",
                     "uint16");

        runner->NextTest();
    }

    // Test Query Vendor Name
    using SuccessCallback_1 = void (*)(void * context, chip::ByteSpan vendorName);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterBasicCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterBasicCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "Basic - Query Vendor Name: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeVendorName(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query Vendor Name: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_1_SuccessResponse(void * context, chip::ByteSpan vendorName)
    {
        ChipLogProgress(chipTool, "Basic - Query Vendor Name: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: vendorName type checking is not implemented yet. Expected type: '%s'", "string");

        if (vendorName.size() > 32)
        {
            ChipLogError(chipTool, "Error: vendorName is too long. Max size is 32 but got '%zu'", vendorName.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query VendorID
    using SuccessCallback_2 = void (*)(void * context, uint16_t vendorID);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{ OnTestSendClusterBasicCommandReadAttribute_2_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterBasicCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "Basic - Query VendorID: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeVendorID(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query VendorID: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_2_SuccessResponse(void * context, uint16_t vendorID)
    {
        ChipLogProgress(chipTool, "Basic - Query VendorID: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: vendorID type checking is not implemented yet. Expected type: '%s'", "uint16");

        runner->NextTest();
    }

    // Test Query Product Name
    using SuccessCallback_3 = void (*)(void * context, chip::ByteSpan productName);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{ OnTestSendClusterBasicCommandReadAttribute_3_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterBasicCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "Basic - Query Product Name: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeProductName(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query Product Name: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_3_SuccessResponse(void * context, chip::ByteSpan productName)
    {
        ChipLogProgress(chipTool, "Basic - Query Product Name: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: productName type checking is not implemented yet. Expected type: '%s'", "string");

        if (productName.size() > 32)
        {
            ChipLogError(chipTool, "Error: productName is too long. Max size is 32 but got '%zu'", productName.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query ProductID
    using SuccessCallback_4 = void (*)(void * context, uint16_t productID);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{ OnTestSendClusterBasicCommandReadAttribute_4_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterBasicCommandReadAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_4()
    {
        ChipLogProgress(chipTool, "Basic - Query ProductID: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeProductID(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query ProductID: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_4_SuccessResponse(void * context, uint16_t productID)
    {
        ChipLogProgress(chipTool, "Basic - Query ProductID: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: productID type checking is not implemented yet. Expected type: '%s'", "uint16");

        runner->NextTest();
    }

    // Test Query User Label
    using SuccessCallback_5 = void (*)(void * context, chip::ByteSpan userLabel);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{ OnTestSendClusterBasicCommandReadAttribute_5_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterBasicCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "Basic - Query User Label: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeUserLabel(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query User Label: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_5_SuccessResponse(void * context, chip::ByteSpan userLabel)
    {
        ChipLogProgress(chipTool, "Basic - Query User Label: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: userLabel type checking is not implemented yet. Expected type: '%s'", "string");

        if (userLabel.size() > 32)
        {
            ChipLogError(chipTool, "Error: userLabel is too long. Max size is 32 but got '%zu'", userLabel.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query User Location
    using SuccessCallback_6 = void (*)(void * context, chip::ByteSpan location);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{ OnTestSendClusterBasicCommandReadAttribute_6_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterBasicCommandReadAttribute_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_6()
    {
        ChipLogProgress(chipTool, "Basic - Query User Location: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeLocation(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query User Location: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_6_SuccessResponse(void * context, chip::ByteSpan location)
    {
        ChipLogProgress(chipTool, "Basic - Query User Location: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: location type checking is not implemented yet. Expected type: '%s'", "string");

        ChipLogError(chipTool, "Warning: location format checking is not implemented yet. Expected format: '%s'",
                     "ISO 3166-1 alpha-2");

        if (location.size() > 2)
        {
            ChipLogError(chipTool, "Error: location is too long. Max size is 2 but got '%zu'", location.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query HardwareVersion
    using SuccessCallback_7 = void (*)(void * context, uint16_t hardwareVersion);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{ OnTestSendClusterBasicCommandReadAttribute_7_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterBasicCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_7()
    {
        ChipLogProgress(chipTool, "Basic - Query HardwareVersion: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeHardwareVersion(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query HardwareVersion: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_7_SuccessResponse(void * context, uint16_t hardwareVersion)
    {
        ChipLogProgress(chipTool, "Basic - Query HardwareVersion: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: hardwareVersion type checking is not implemented yet. Expected type: '%s'", "uint16");

        runner->NextTest();
    }

    // Test Query HardwareVersionString
    using SuccessCallback_8 = void (*)(void * context, chip::ByteSpan hardwareVersionString);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{ OnTestSendClusterBasicCommandReadAttribute_8_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterBasicCommandReadAttribute_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_8()
    {
        ChipLogProgress(chipTool, "Basic - Query HardwareVersionString: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeHardwareVersionString(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query HardwareVersionString: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_8_SuccessResponse(void * context, chip::ByteSpan hardwareVersionString)
    {
        ChipLogProgress(chipTool, "Basic - Query HardwareVersionString: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: hardwareVersionString type checking is not implemented yet. Expected type: '%s'",
                     "string");

        if (hardwareVersionString.size() < 1)
        {
            ChipLogError(chipTool, "Error: hardwareVersionString is too short. Min size is 1 but got '%zu'",
                         hardwareVersionString.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (hardwareVersionString.size() > 64)
        {
            ChipLogError(chipTool, "Error: hardwareVersionString is too long. Max size is 64 but got '%zu'",
                         hardwareVersionString.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query SoftwareVersion
    using SuccessCallback_9 = void (*)(void * context, uint32_t softwareVersion);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{ OnTestSendClusterBasicCommandReadAttribute_9_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterBasicCommandReadAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_9()
    {
        ChipLogProgress(chipTool, "Basic - Query SoftwareVersion: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeSoftwareVersion(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query SoftwareVersion: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_9_SuccessResponse(void * context, uint32_t softwareVersion)
    {
        ChipLogProgress(chipTool, "Basic - Query SoftwareVersion: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: softwareVersion type checking is not implemented yet. Expected type: '%s'", "uint32");

        runner->NextTest();
    }

    // Test Query SoftwareVersionString
    using SuccessCallback_10 = void (*)(void * context, chip::ByteSpan softwareVersionString);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterBasicCommandReadAttribute_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterBasicCommandReadAttribute_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_10()
    {
        ChipLogProgress(chipTool, "Basic - Query SoftwareVersionString: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeSoftwareVersionString(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query SoftwareVersionString: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_10_SuccessResponse(void * context, chip::ByteSpan softwareVersionString)
    {
        ChipLogProgress(chipTool, "Basic - Query SoftwareVersionString: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: softwareVersionString type checking is not implemented yet. Expected type: '%s'",
                     "string");

        ChipLogError(chipTool, "Warning: softwareVersionString format checking is not implemented yet. Expected format: '%s'",
                     "ASCII");

        if (softwareVersionString.size() < 1)
        {
            ChipLogError(chipTool, "Error: softwareVersionString is too short. Min size is 1 but got '%zu'",
                         softwareVersionString.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (softwareVersionString.size() > 64)
        {
            ChipLogError(chipTool, "Error: softwareVersionString is too long. Max size is 64 but got '%zu'",
                         softwareVersionString.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query ManufacturingDate
    using SuccessCallback_11 = void (*)(void * context, chip::ByteSpan manufacturingDate);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterBasicCommandReadAttribute_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterBasicCommandReadAttribute_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_11()
    {
        ChipLogProgress(chipTool, "Basic - Query ManufacturingDate: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeManufacturingDate(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query ManufacturingDate: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_11_SuccessResponse(void * context, chip::ByteSpan manufacturingDate)
    {
        ChipLogProgress(chipTool, "Basic - Query ManufacturingDate: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: manufacturingDate type checking is not implemented yet. Expected type: '%s'", "string");

        ChipLogError(chipTool, "Warning: manufacturingDate format checking is not implemented yet. Expected format: '%s'",
                     "ISO 8601");

        if (manufacturingDate.size() < 8)
        {
            ChipLogError(chipTool, "Error: manufacturingDate is too short. Min size is 8 but got '%zu'", manufacturingDate.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (manufacturingDate.size() > 16)
        {
            ChipLogError(chipTool, "Error: manufacturingDate is too long. Max size is 16 but got '%zu'", manufacturingDate.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query PartNumber
    using SuccessCallback_12 = void (*)(void * context, chip::ByteSpan partNumber);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{
        OnTestSendClusterBasicCommandReadAttribute_12_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{
        OnTestSendClusterBasicCommandReadAttribute_12_FailureResponse, this
    };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_12()
    {
        ChipLogProgress(chipTool, "Basic - Query PartNumber: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributePartNumber(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query PartNumber: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_12_SuccessResponse(void * context, chip::ByteSpan partNumber)
    {
        ChipLogProgress(chipTool, "Basic - Query PartNumber: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: partNumber type checking is not implemented yet. Expected type: '%s'", "string");

        if (partNumber.size() > 32)
        {
            ChipLogError(chipTool, "Error: partNumber is too long. Max size is 32 but got '%zu'", partNumber.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query ProductURL
    using SuccessCallback_13 = void (*)(void * context, chip::ByteSpan productURL);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterBasicCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterBasicCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_13()
    {
        ChipLogProgress(chipTool, "Basic - Query ProductURL: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeProductURL(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query ProductURL: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_13_SuccessResponse(void * context, chip::ByteSpan productURL)
    {
        ChipLogProgress(chipTool, "Basic - Query ProductURL: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: productURL type checking is not implemented yet. Expected type: '%s'", "string");

        ChipLogError(chipTool, "Warning: productURL format checking is not implemented yet. Expected format: '%s'", "RFC3986");

        if (productURL.size() > 256)
        {
            ChipLogError(chipTool, "Error: productURL is too long. Max size is 256 but got '%zu'", productURL.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query ProductLabel
    using SuccessCallback_14 = void (*)(void * context, chip::ByteSpan productLabel);
    chip::Callback::Callback<SuccessCallback_14> mOnSuccessCallback_14{
        OnTestSendClusterBasicCommandReadAttribute_14_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_14{
        OnTestSendClusterBasicCommandReadAttribute_14_FailureResponse, this
    };
    bool mIsFailureExpected_14 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_14()
    {
        ChipLogProgress(chipTool, "Basic - Query ProductLabel: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeProductLabel(mOnSuccessCallback_14.Cancel(), mOnFailureCallback_14.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_14_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query ProductLabel: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_14 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_14_SuccessResponse(void * context, chip::ByteSpan productLabel)
    {
        ChipLogProgress(chipTool, "Basic - Query ProductLabel: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_14 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: productLabel type checking is not implemented yet. Expected type: '%s'", "string");

        if (productLabel.size() > 64)
        {
            ChipLogError(chipTool, "Error: productLabel is too long. Max size is 64 but got '%zu'", productLabel.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query SerialNumber
    using SuccessCallback_15 = void (*)(void * context, chip::ByteSpan serialNumber);
    chip::Callback::Callback<SuccessCallback_15> mOnSuccessCallback_15{
        OnTestSendClusterBasicCommandReadAttribute_15_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_15{
        OnTestSendClusterBasicCommandReadAttribute_15_FailureResponse, this
    };
    bool mIsFailureExpected_15 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_15()
    {
        ChipLogProgress(chipTool, "Basic - Query SerialNumber: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeSerialNumber(mOnSuccessCallback_15.Cancel(), mOnFailureCallback_15.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_15_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query SerialNumber: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_15 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_15_SuccessResponse(void * context, chip::ByteSpan serialNumber)
    {
        ChipLogProgress(chipTool, "Basic - Query SerialNumber: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_15 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: serialNumber type checking is not implemented yet. Expected type: '%s'", "string");

        if (serialNumber.size() > 32)
        {
            ChipLogError(chipTool, "Error: serialNumber is too long. Max size is 32 but got '%zu'", serialNumber.size());
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Query LocalConfigDisabled
    using SuccessCallback_16 = void (*)(void * context, uint8_t localConfigDisabled);
    chip::Callback::Callback<SuccessCallback_16> mOnSuccessCallback_16{
        OnTestSendClusterBasicCommandReadAttribute_16_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_16{
        OnTestSendClusterBasicCommandReadAttribute_16_FailureResponse, this
    };
    bool mIsFailureExpected_16 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_16()
    {
        ChipLogProgress(chipTool, "Basic - Query LocalConfigDisabled: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeLocalConfigDisabled(mOnSuccessCallback_16.Cancel(), mOnFailureCallback_16.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_16_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query LocalConfigDisabled: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_16 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_16_SuccessResponse(void * context, uint8_t localConfigDisabled)
    {
        ChipLogProgress(chipTool, "Basic - Query LocalConfigDisabled: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_16 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: localConfigDisabled type checking is not implemented yet. Expected type: '%s'", "boolean");

        runner->NextTest();
    }

    // Test Query Reachable
    using SuccessCallback_17 = void (*)(void * context, uint8_t reachable);
    chip::Callback::Callback<SuccessCallback_17> mOnSuccessCallback_17{
        OnTestSendClusterBasicCommandReadAttribute_17_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_17{
        OnTestSendClusterBasicCommandReadAttribute_17_FailureResponse, this
    };
    bool mIsFailureExpected_17 = 0;

    CHIP_ERROR TestSendClusterBasicCommandReadAttribute_17()
    {
        ChipLogProgress(chipTool, "Basic - Query Reachable: Sending command...");

        chip::Controller::BasicCluster cluster;
        cluster.Associate(mDevice, 0);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeReachable(mOnSuccessCallback_17.Cancel(), mOnFailureCallback_17.Cancel());

        return err;
    }

    static void OnTestSendClusterBasicCommandReadAttribute_17_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Basic - Query Reachable: Failure Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (status == EMBER_ZCL_STATUS_UNSUPPORTED_ATTRIBUTE)
        {
            runner->NextTest();
            return;
        }

        if (runner->mIsFailureExpected_17 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterBasicCommandReadAttribute_17_SuccessResponse(void * context, uint8_t reachable)
    {
        ChipLogProgress(chipTool, "Basic - Query Reachable: Success Response");

        Test_TC_DM_1_1 * runner = reinterpret_cast<Test_TC_DM_1_1 *>(context);

        if (runner->mIsFailureExpected_17 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        ChipLogError(chipTool, "Warning: reachable type checking is not implemented yet. Expected type: '%s'", "boolean");

        runner->NextTest();
    }
};

class Test_TC_DM_3_1 : public TestCommand
{
public:
    Test_TC_DM_3_1() : TestCommand("Test_TC_DM_3_1"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_DM_3_1: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_DM_3_1: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 0;

    //
    // Tests methods
    //
};

class Test_TC_CC_3_4 : public TestCommand
{
public:
    Test_TC_CC_3_4() : TestCommand("Test_TC_CC_3_4"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_3_4: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandOn_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterColorControlCommandMoveToHue_2();
            break;
        case 3:
            err = TestSendClusterColorControlCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterColorControlCommandMoveToHue_4();
            break;
        case 5:
            err = TestSendClusterColorControlCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterColorControlCommandMoveToHue_6();
            break;
        case 7:
            err = TestSendClusterColorControlCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterColorControlCommandMoveToHue_8();
            break;
        case 9:
            err = TestSendClusterColorControlCommandReadAttribute_9();
            break;
        case 10:
            err = TestSendClusterColorControlCommandMoveHue_10();
            break;
        case 11:
            err = TestSendClusterColorControlCommandReadAttribute_11();
            break;
        case 12:
            err = TestSendClusterColorControlCommandMoveHue_12();
            break;
        case 13:
            err = TestSendClusterColorControlCommandReadAttribute_13();
            break;
        case 14:
            err = TestSendClusterColorControlCommandMoveHue_14();
            break;
        case 15:
            err = TestSendClusterColorControlCommandReadAttribute_15();
            break;
        case 16:
            err = TestSendClusterColorControlCommandMoveHue_16();
            break;
        case 17:
            err = TestSendClusterColorControlCommandReadAttribute_17();
            break;
        case 18:
            err = TestSendClusterColorControlCommandStepHue_18();
            break;
        case 19:
            err = TestSendClusterColorControlCommandReadAttribute_19();
            break;
        case 20:
            err = TestSendClusterColorControlCommandStepHue_20();
            break;
        case 21:
            err = TestSendClusterColorControlCommandReadAttribute_21();
            break;
        case 22:
            err = TestSendClusterColorControlCommandReadAttribute_22();
            break;
        case 23:
            err = TestSendClusterColorControlCommandMoveToSaturation_23();
            break;
        case 24:
            err = TestSendClusterColorControlCommandReadAttribute_24();
            break;
        case 25:
            err = TestSendClusterColorControlCommandMoveSaturation_25();
            break;
        case 26:
            err = TestSendClusterColorControlCommandReadAttribute_26();
            break;
        case 27:
            err = TestSendClusterColorControlCommandMoveSaturation_27();
            break;
        case 28:
            err = TestSendClusterColorControlCommandReadAttribute_28();
            break;
        case 29:
            err = TestSendClusterColorControlCommandStepSaturation_29();
            break;
        case 30:
            err = TestSendClusterColorControlCommandReadAttribute_30();
            break;
        case 31:
            err = TestSendClusterColorControlCommandStepSaturation_31();
            break;
        case 32:
            err = TestSendClusterColorControlCommandReadAttribute_32();
            break;
        case 33:
            err = TestSendClusterColorControlCommandMoveToHueAndSaturation_33();
            break;
        case 34:
            err = TestSendClusterColorControlCommandReadAttribute_34();
            break;
        case 35:
            err = TestSendClusterColorControlCommandReadAttribute_35();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_3_4: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 36;

    //
    // Tests methods
    //

    // Test Turn on light for color control tests
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandOn_0_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{ OnTestSendClusterOnOffCommandOn_0_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOn_0()
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.On(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOn_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOn_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after on command
    using SuccessCallback_1 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move to hue shortest distance command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterColorControlCommandMoveToHue_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterColorControlCommandMoveToHue_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToHue_2()
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue shortest distance command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t hueArgument             = 150;
        uint8_t directionArgument       = 0;
        uint16_t transitionTimeArgument = 100U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToHue(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel(), hueArgument, directionArgument,
                                transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue shortest distance command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue shortest distance command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_3 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_3()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move to hue longest distance command
    using SuccessCallback_4 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterColorControlCommandMoveToHue_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterColorControlCommandMoveToHue_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToHue_4()
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue longest distance command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t hueArgument             = 200;
        uint8_t directionArgument       = 1;
        uint16_t transitionTimeArgument = 100U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToHue(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel(), hueArgument, directionArgument,
                                transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue longest distance command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_4_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue longest distance command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_5 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterColorControlCommandReadAttribute_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterColorControlCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_5()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_5_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move to hue up command
    using SuccessCallback_6 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterColorControlCommandMoveToHue_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterColorControlCommandMoveToHue_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToHue_6()
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t hueArgument             = 250;
        uint8_t directionArgument       = 2;
        uint16_t transitionTimeArgument = 100U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToHue(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel(), hueArgument, directionArgument,
                                transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue up command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_6_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue up command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_7 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterColorControlCommandReadAttribute_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterColorControlCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_7()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_7_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move to hue down command
    using SuccessCallback_8 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterColorControlCommandMoveToHue_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterColorControlCommandMoveToHue_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToHue_8()
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue down command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t hueArgument             = 225;
        uint8_t directionArgument       = 3;
        uint16_t transitionTimeArgument = 100U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToHue(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel(), hueArgument, directionArgument,
                                transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue down command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToHue_8_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move to hue down command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_9 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterColorControlCommandReadAttribute_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterColorControlCommandReadAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_9()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_9_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move hue up command
    using SuccessCallback_10 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterColorControlCommandMoveHue_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterColorControlCommandMoveHue_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveHue_10()
    {
        ChipLogProgress(chipTool, "Color Control - Move hue up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 1;
        uint8_t rateArgument            = 50;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveHue(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel(), moveModeArgument, rateArgument,
                              optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveHue_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue up command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveHue_10_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue up command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_11 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterColorControlCommandReadAttribute_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterColorControlCommandReadAttribute_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_11()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_11_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move hue stop command
    using SuccessCallback_12 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{
        OnTestSendClusterColorControlCommandMoveHue_12_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{
        OnTestSendClusterColorControlCommandMoveHue_12_FailureResponse, this
    };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveHue_12()
    {
        ChipLogProgress(chipTool, "Color Control - Move hue stop command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 0;
        uint8_t rateArgument            = 50;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveHue(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel(), moveModeArgument, rateArgument,
                              optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveHue_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue stop command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveHue_12_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue stop command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_13 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_13()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move hue down command
    using SuccessCallback_14 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_14> mOnSuccessCallback_14{
        OnTestSendClusterColorControlCommandMoveHue_14_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_14{
        OnTestSendClusterColorControlCommandMoveHue_14_FailureResponse, this
    };
    bool mIsFailureExpected_14 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveHue_14()
    {
        ChipLogProgress(chipTool, "Color Control - Move hue down command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 3;
        uint8_t rateArgument            = 50;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveHue(mOnSuccessCallback_14.Cancel(), mOnFailureCallback_14.Cancel(), moveModeArgument, rateArgument,
                              optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveHue_14_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue down command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_14 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveHue_14_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue down command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_14 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_15 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_15> mOnSuccessCallback_15{
        OnTestSendClusterColorControlCommandReadAttribute_15_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_15{
        OnTestSendClusterColorControlCommandReadAttribute_15_FailureResponse, this
    };
    bool mIsFailureExpected_15 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_15()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_15.Cancel(), mOnFailureCallback_15.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_15_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_15 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_15_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_15 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move hue stop command
    using SuccessCallback_16 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_16> mOnSuccessCallback_16{
        OnTestSendClusterColorControlCommandMoveHue_16_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_16{
        OnTestSendClusterColorControlCommandMoveHue_16_FailureResponse, this
    };
    bool mIsFailureExpected_16 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveHue_16()
    {
        ChipLogProgress(chipTool, "Color Control - Move hue stop command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 0;
        uint8_t rateArgument            = 50;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveHue(mOnSuccessCallback_16.Cancel(), mOnFailureCallback_16.Cancel(), moveModeArgument, rateArgument,
                              optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveHue_16_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue stop command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_16 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveHue_16_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move hue stop command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_16 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_17 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_17> mOnSuccessCallback_17{
        OnTestSendClusterColorControlCommandReadAttribute_17_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_17{
        OnTestSendClusterColorControlCommandReadAttribute_17_FailureResponse, this
    };
    bool mIsFailureExpected_17 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_17()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_17.Cancel(), mOnFailureCallback_17.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_17_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_17 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_17_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_17 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step hue up command
    using SuccessCallback_18 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_18> mOnSuccessCallback_18{
        OnTestSendClusterColorControlCommandStepHue_18_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_18{
        OnTestSendClusterColorControlCommandStepHue_18_FailureResponse, this
    };
    bool mIsFailureExpected_18 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepHue_18()
    {
        ChipLogProgress(chipTool, "Color Control - Step hue up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument        = 1;
        uint8_t stepSizeArgument        = 5;
        uint8_t transitionTimeArgument  = 25;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.StepHue(mOnSuccessCallback_18.Cancel(), mOnFailureCallback_18.Cancel(), stepModeArgument, stepSizeArgument,
                              transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepHue_18_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step hue up command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_18 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepHue_18_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step hue up command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_18 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_19 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_19> mOnSuccessCallback_19{
        OnTestSendClusterColorControlCommandReadAttribute_19_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_19{
        OnTestSendClusterColorControlCommandReadAttribute_19_FailureResponse, this
    };
    bool mIsFailureExpected_19 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_19()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_19.Cancel(), mOnFailureCallback_19.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_19_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_19 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_19_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_19 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step hue down command
    using SuccessCallback_20 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_20> mOnSuccessCallback_20{
        OnTestSendClusterColorControlCommandStepHue_20_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_20{
        OnTestSendClusterColorControlCommandStepHue_20_FailureResponse, this
    };
    bool mIsFailureExpected_20 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepHue_20()
    {
        ChipLogProgress(chipTool, "Color Control - Step hue down command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument        = 3;
        uint8_t stepSizeArgument        = 5;
        uint8_t transitionTimeArgument  = 25;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.StepHue(mOnSuccessCallback_20.Cancel(), mOnFailureCallback_20.Cancel(), stepModeArgument, stepSizeArgument,
                              transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepHue_20_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step hue down command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_20 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepHue_20_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step hue down command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_20 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_21 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_21> mOnSuccessCallback_21{
        OnTestSendClusterColorControlCommandReadAttribute_21_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_21{
        OnTestSendClusterColorControlCommandReadAttribute_21_FailureResponse, this
    };
    bool mIsFailureExpected_21 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_21()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_21.Cancel(), mOnFailureCallback_21.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_21_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_21 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_21_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_21 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched before any change
    using SuccessCallback_22 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_22> mOnSuccessCallback_22{
        OnTestSendClusterColorControlCommandReadAttribute_22_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_22{
        OnTestSendClusterColorControlCommandReadAttribute_22_FailureResponse, this
    };
    bool mIsFailureExpected_22 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_22()
    {
        ChipLogProgress(chipTool, "Color Control - Check Saturation attribute value matched before any change: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_22.Cancel(), mOnFailureCallback_22.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_22_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Check Saturation attribute value matched before any change: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_22 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_22_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(chipTool, "Color Control - Check Saturation attribute value matched before any change: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_22 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move to saturation command
    using SuccessCallback_23 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_23> mOnSuccessCallback_23{
        OnTestSendClusterColorControlCommandMoveToSaturation_23_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_23{
        OnTestSendClusterColorControlCommandMoveToSaturation_23_FailureResponse, this
    };
    bool mIsFailureExpected_23 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToSaturation_23()
    {
        ChipLogProgress(chipTool, "Color Control - Move to saturation command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t saturationArgument      = 90;
        uint16_t transitionTimeArgument = 10U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToSaturation(mOnSuccessCallback_23.Cancel(), mOnFailureCallback_23.Cancel(), saturationArgument,
                                       transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToSaturation_23_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move to saturation command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_23 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToSaturation_23_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move to saturation command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_23 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_24 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_24> mOnSuccessCallback_24{
        OnTestSendClusterColorControlCommandReadAttribute_24_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_24{
        OnTestSendClusterColorControlCommandReadAttribute_24_FailureResponse, this
    };
    bool mIsFailureExpected_24 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_24()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_24.Cancel(), mOnFailureCallback_24.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_24_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_24 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_24_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_24 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move saturation up command
    using SuccessCallback_25 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_25> mOnSuccessCallback_25{
        OnTestSendClusterColorControlCommandMoveSaturation_25_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_25{
        OnTestSendClusterColorControlCommandMoveSaturation_25_FailureResponse, this
    };
    bool mIsFailureExpected_25 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveSaturation_25()
    {
        ChipLogProgress(chipTool, "Color Control - Move saturation up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 1;
        uint8_t rateArgument            = 5;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveSaturation(mOnSuccessCallback_25.Cancel(), mOnFailureCallback_25.Cancel(), moveModeArgument, rateArgument,
                                     optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveSaturation_25_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move saturation up command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_25 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveSaturation_25_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move saturation up command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_25 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_26 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_26> mOnSuccessCallback_26{
        OnTestSendClusterColorControlCommandReadAttribute_26_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_26{
        OnTestSendClusterColorControlCommandReadAttribute_26_FailureResponse, this
    };
    bool mIsFailureExpected_26 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_26()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_26.Cancel(), mOnFailureCallback_26.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_26_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_26 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_26_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_26 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move saturation down command
    using SuccessCallback_27 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_27> mOnSuccessCallback_27{
        OnTestSendClusterColorControlCommandMoveSaturation_27_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_27{
        OnTestSendClusterColorControlCommandMoveSaturation_27_FailureResponse, this
    };
    bool mIsFailureExpected_27 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveSaturation_27()
    {
        ChipLogProgress(chipTool, "Color Control - Move saturation down command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 3;
        uint8_t rateArgument            = 5;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveSaturation(mOnSuccessCallback_27.Cancel(), mOnFailureCallback_27.Cancel(), moveModeArgument, rateArgument,
                                     optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveSaturation_27_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move saturation down command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_27 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveSaturation_27_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move saturation down command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_27 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_28 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_28> mOnSuccessCallback_28{
        OnTestSendClusterColorControlCommandReadAttribute_28_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_28{
        OnTestSendClusterColorControlCommandReadAttribute_28_FailureResponse, this
    };
    bool mIsFailureExpected_28 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_28()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_28.Cancel(), mOnFailureCallback_28.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_28_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_28 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_28_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_28 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step saturation up command
    using SuccessCallback_29 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_29> mOnSuccessCallback_29{
        OnTestSendClusterColorControlCommandStepSaturation_29_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_29{
        OnTestSendClusterColorControlCommandStepSaturation_29_FailureResponse, this
    };
    bool mIsFailureExpected_29 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepSaturation_29()
    {
        ChipLogProgress(chipTool, "Color Control - Step saturation up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument        = 1;
        uint8_t stepSizeArgument        = 15;
        uint8_t transitionTimeArgument  = 10;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.StepSaturation(mOnSuccessCallback_29.Cancel(), mOnFailureCallback_29.Cancel(), stepModeArgument,
                                     stepSizeArgument, transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepSaturation_29_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step saturation up command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_29 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepSaturation_29_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step saturation up command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_29 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_30 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_30> mOnSuccessCallback_30{
        OnTestSendClusterColorControlCommandReadAttribute_30_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_30{
        OnTestSendClusterColorControlCommandReadAttribute_30_FailureResponse, this
    };
    bool mIsFailureExpected_30 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_30()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_30.Cancel(), mOnFailureCallback_30.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_30_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_30 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_30_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_30 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step saturation down command
    using SuccessCallback_31 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_31> mOnSuccessCallback_31{
        OnTestSendClusterColorControlCommandStepSaturation_31_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_31{
        OnTestSendClusterColorControlCommandStepSaturation_31_FailureResponse, this
    };
    bool mIsFailureExpected_31 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepSaturation_31()
    {
        ChipLogProgress(chipTool, "Color Control - Step saturation down command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument        = 3;
        uint8_t stepSizeArgument        = 20;
        uint8_t transitionTimeArgument  = 10;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.StepSaturation(mOnSuccessCallback_31.Cancel(), mOnFailureCallback_31.Cancel(), stepModeArgument,
                                     stepSizeArgument, transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepSaturation_31_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step saturation down command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_31 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepSaturation_31_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step saturation down command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_31 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_32 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_32> mOnSuccessCallback_32{
        OnTestSendClusterColorControlCommandReadAttribute_32_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_32{
        OnTestSendClusterColorControlCommandReadAttribute_32_FailureResponse, this
    };
    bool mIsFailureExpected_32 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_32()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_32.Cancel(), mOnFailureCallback_32.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_32_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_32 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_32_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_32 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move To current hue and saturation command
    using SuccessCallback_33 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_33> mOnSuccessCallback_33{
        OnTestSendClusterColorControlCommandMoveToHueAndSaturation_33_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_33{
        OnTestSendClusterColorControlCommandMoveToHueAndSaturation_33_FailureResponse, this
    };
    bool mIsFailureExpected_33 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToHueAndSaturation_33()
    {
        ChipLogProgress(chipTool, "Color Control - Move To current hue and saturation command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t hueArgument             = 40;
        uint8_t saturationArgument      = 160;
        uint16_t transitionTimeArgument = 10U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToHueAndSaturation(mOnSuccessCallback_33.Cancel(), mOnFailureCallback_33.Cancel(), hueArgument,
                                             saturationArgument, transitionTimeArgument, optionsMaskArgument,
                                             optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToHueAndSaturation_33_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move To current hue and saturation command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_33 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToHueAndSaturation_33_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move To current hue and saturation command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_33 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current hue attribute value matched the value sent by the last command
    using SuccessCallback_34 = void (*)(void * context, uint8_t currentHue);
    chip::Callback::Callback<SuccessCallback_34> mOnSuccessCallback_34{
        OnTestSendClusterColorControlCommandReadAttribute_34_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_34{
        OnTestSendClusterColorControlCommandReadAttribute_34_FailureResponse, this
    };
    bool mIsFailureExpected_34 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_34()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentHue(mOnSuccessCallback_34.Cancel(), mOnFailureCallback_34.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_34_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_34 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_34_SuccessResponse(void * context, uint8_t currentHue)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current hue attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_34 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_35 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_35> mOnSuccessCallback_35{
        OnTestSendClusterColorControlCommandReadAttribute_35_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_35{
        OnTestSendClusterColorControlCommandReadAttribute_35_FailureResponse, this
    };
    bool mIsFailureExpected_35 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_35()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_35.Cancel(), mOnFailureCallback_35.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_35_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_35 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_35_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_3_4 * runner = reinterpret_cast<Test_TC_CC_3_4 *>(context);

        if (runner->mIsFailureExpected_35 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_CC_5 : public TestCommand
{
public:
    Test_TC_CC_5() : TestCommand("Test_TC_CC_5"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_5: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandOn_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterColorControlCommandMoveToColor_2();
            break;
        case 3:
            err = TestSendClusterColorControlCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterColorControlCommandReadAttribute_4();
            break;
        case 5:
            err = TestSendClusterColorControlCommandMoveColor_5();
            break;
        case 6:
            err = TestSendClusterColorControlCommandReadAttribute_6();
            break;
        case 7:
            err = TestSendClusterColorControlCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterColorControlCommandStopMoveStep_8();
            break;
        case 9:
            err = TestSendClusterColorControlCommandReadAttribute_9();
            break;
        case 10:
            err = TestSendClusterColorControlCommandReadAttribute_10();
            break;
        case 11:
            err = TestSendClusterColorControlCommandStepColor_11();
            break;
        case 12:
            err = TestSendClusterColorControlCommandReadAttribute_12();
            break;
        case 13:
            err = TestSendClusterColorControlCommandReadAttribute_13();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_5: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 14;

    //
    // Tests methods
    //

    // Test Turn on light for color control tests
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandOn_0_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{ OnTestSendClusterOnOffCommandOn_0_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOn_0()
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.On(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOn_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOn_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after on command
    using SuccessCallback_1 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move to Color command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterColorControlCommandMoveToColor_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterColorControlCommandMoveToColor_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToColor_2()
    {
        ChipLogProgress(chipTool, "Color Control - Move to Color command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t colorXArgument         = 200U;
        uint16_t colorYArgument         = 300U;
        uint16_t transitionTimeArgument = 20U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveToColor(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel(), colorXArgument, colorYArgument,
                                  transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToColor_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move to Color command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToColor_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move to Color command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current y attribute value matched the value sent by the last command
    using SuccessCallback_3 = void (*)(void * context, uint16_t currentX);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_3()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentX(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse(void * context, uint16_t currentX)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current x attribute value matched the value sent by the last command
    using SuccessCallback_4 = void (*)(void * context, uint16_t currentY);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterColorControlCommandReadAttribute_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterColorControlCommandReadAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_4()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentY(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_4_SuccessResponse(void * context, uint16_t currentY)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move Color command
    using SuccessCallback_5 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterColorControlCommandMoveColor_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterColorControlCommandMoveColor_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveColor_5()
    {
        ChipLogProgress(chipTool, "Color Control - Move Color command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int16_t rateXArgument           = 15;
        int16_t rateYArgument           = 20;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.MoveColor(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel(), rateXArgument, rateYArgument,
                                optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveColor_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move Color command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveColor_5_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move Color command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current x attribute value matched the value sent by the last command
    using SuccessCallback_6 = void (*)(void * context, uint16_t currentX);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterColorControlCommandReadAttribute_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterColorControlCommandReadAttribute_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_6()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentX(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_6_SuccessResponse(void * context, uint16_t currentX)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current y attribute value matched the value sent by the last command
    using SuccessCallback_7 = void (*)(void * context, uint16_t currentY);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterColorControlCommandReadAttribute_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterColorControlCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_7()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentY(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_7_SuccessResponse(void * context, uint16_t currentY)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Stop Move Step command
    using SuccessCallback_8 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterColorControlCommandStopMoveStep_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterColorControlCommandStopMoveStep_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStopMoveStep_8()
    {
        ChipLogProgress(chipTool, "Color Control - Stop Move Step command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.StopMoveStep(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel(), optionsMaskArgument,
                                   optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStopMoveStep_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Stop Move Step command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStopMoveStep_8_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Stop Move Step command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current x attribute value matched the value sent by the last command
    using SuccessCallback_9 = void (*)(void * context, uint16_t currentX);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterColorControlCommandReadAttribute_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterColorControlCommandReadAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_9()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentX(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_9_SuccessResponse(void * context, uint16_t currentX)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current y attribute value matched the value sent by the last command
    using SuccessCallback_10 = void (*)(void * context, uint16_t currentY);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterColorControlCommandReadAttribute_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterColorControlCommandReadAttribute_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_10()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentY(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_10_SuccessResponse(void * context, uint16_t currentY)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step Color command
    using SuccessCallback_11 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterColorControlCommandStepColor_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterColorControlCommandStepColor_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepColor_11()
    {
        ChipLogProgress(chipTool, "Color Control - Step Color command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        int16_t stepXArgument           = 15;
        int16_t stepYArgument           = 20;
        uint16_t transitionTimeArgument = 50U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.StepColor(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel(), stepXArgument, stepYArgument,
                                transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepColor_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step Color command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepColor_11_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step Color command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current x attribute value matched the value sent by the last command
    using SuccessCallback_12 = void (*)(void * context, uint16_t currentX);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{
        OnTestSendClusterColorControlCommandReadAttribute_12_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{
        OnTestSendClusterColorControlCommandReadAttribute_12_FailureResponse, this
    };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_12()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentX(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_12_SuccessResponse(void * context, uint16_t currentX)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current x attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check current y attribute value matched the value sent by the last command
    using SuccessCallback_13 = void (*)(void * context, uint16_t currentY);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_13()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentY(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse(void * context, uint16_t currentY)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check current y attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_5 * runner = reinterpret_cast<Test_TC_CC_5 *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_CC_6 : public TestCommand
{
public:
    Test_TC_CC_6() : TestCommand("Test_TC_CC_6"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_6: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandOn_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterColorControlCommandMoveToColorTemperature_2();
            break;
        case 3:
            err = TestSendClusterColorControlCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterColorControlCommandMoveColorTemperature_4();
            break;
        case 5:
            err = TestSendClusterColorControlCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterColorControlCommandMoveColorTemperature_6();
            break;
        case 7:
            err = TestSendClusterColorControlCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterColorControlCommandMoveColorTemperature_8();
            break;
        case 9:
            err = TestSendClusterColorControlCommandReadAttribute_9();
            break;
        case 10:
            err = TestSendClusterColorControlCommandStepColorTemperature_10();
            break;
        case 11:
            err = TestSendClusterColorControlCommandReadAttribute_11();
            break;
        case 12:
            err = TestSendClusterColorControlCommandStepColorTemperature_12();
            break;
        case 13:
            err = TestSendClusterColorControlCommandReadAttribute_13();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_6: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 14;

    //
    // Tests methods
    //

    // Test Turn on light for color control tests
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandOn_0_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{ OnTestSendClusterOnOffCommandOn_0_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOn_0()
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.On(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOn_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOn_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after on command
    using SuccessCallback_1 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move To Color Temperature command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterColorControlCommandMoveToColorTemperature_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterColorControlCommandMoveToColorTemperature_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveToColorTemperature_2()
    {
        ChipLogProgress(chipTool, "Color Control - Move To Color Temperature command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t colorTemperatureArgument = 100U;
        uint16_t transitionTimeArgument   = 10U;
        uint8_t optionsMaskArgument       = 0;
        uint8_t optionsOverrideArgument   = 0;
        err = cluster.MoveToColorTemperature(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel(), colorTemperatureArgument,
                                             transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveToColorTemperature_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move To Color Temperature command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveToColorTemperature_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move To Color Temperature command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current color temprature
    using SuccessCallback_3 = void (*)(void * context, uint16_t colorTemperature);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeColorTemperature(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse(void * context, uint16_t colorTemperature)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move up color temperature command
    using SuccessCallback_4 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterColorControlCommandMoveColorTemperature_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterColorControlCommandMoveColorTemperature_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveColorTemperature_4()
    {
        ChipLogProgress(chipTool, "Color Control - Move up color temperature command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument                 = 1;
        uint16_t rateArgument                    = 10U;
        uint16_t colorTemperatureMinimumArgument = 1U;
        uint16_t colorTemperatureMaximumArgument = 255U;
        uint8_t optionsMaskArgument              = 0;
        uint8_t optionsOverrideArgument          = 0;
        err = cluster.MoveColorTemperature(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel(), moveModeArgument,
                                           rateArgument, colorTemperatureMinimumArgument, colorTemperatureMaximumArgument,
                                           optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveColorTemperature_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move up color temperature command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveColorTemperature_4_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move up color temperature command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current color temprature
    using SuccessCallback_5 = void (*)(void * context, uint16_t colorTemperature);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterColorControlCommandReadAttribute_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterColorControlCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeColorTemperature(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_5_SuccessResponse(void * context, uint16_t colorTemperature)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Stop Color Temperature command
    using SuccessCallback_6 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterColorControlCommandMoveColorTemperature_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterColorControlCommandMoveColorTemperature_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveColorTemperature_6()
    {
        ChipLogProgress(chipTool, "Color Control - Stop Color Temperature command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument                 = 0;
        uint16_t rateArgument                    = 10U;
        uint16_t colorTemperatureMinimumArgument = 1U;
        uint16_t colorTemperatureMaximumArgument = 255U;
        uint8_t optionsMaskArgument              = 0;
        uint8_t optionsOverrideArgument          = 0;
        err = cluster.MoveColorTemperature(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel(), moveModeArgument,
                                           rateArgument, colorTemperatureMinimumArgument, colorTemperatureMaximumArgument,
                                           optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveColorTemperature_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Stop Color Temperature command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveColorTemperature_6_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Stop Color Temperature command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current color temprature
    using SuccessCallback_7 = void (*)(void * context, uint16_t colorTemperature);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterColorControlCommandReadAttribute_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterColorControlCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_7()
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeColorTemperature(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_7_SuccessResponse(void * context, uint16_t colorTemperature)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Move down color temperature command
    using SuccessCallback_8 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterColorControlCommandMoveColorTemperature_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterColorControlCommandMoveColorTemperature_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandMoveColorTemperature_8()
    {
        ChipLogProgress(chipTool, "Color Control - Move down color temperature command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument                 = 3;
        uint16_t rateArgument                    = 20U;
        uint16_t colorTemperatureMinimumArgument = 1U;
        uint16_t colorTemperatureMaximumArgument = 255U;
        uint8_t optionsMaskArgument              = 0;
        uint8_t optionsOverrideArgument          = 0;
        err = cluster.MoveColorTemperature(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel(), moveModeArgument,
                                           rateArgument, colorTemperatureMinimumArgument, colorTemperatureMaximumArgument,
                                           optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandMoveColorTemperature_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Move down color temperature command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandMoveColorTemperature_8_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Move down color temperature command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current color temprature
    using SuccessCallback_9 = void (*)(void * context, uint16_t colorTemperature);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterColorControlCommandReadAttribute_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterColorControlCommandReadAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_9()
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeColorTemperature(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_9_SuccessResponse(void * context, uint16_t colorTemperature)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step up color temperature command
    using SuccessCallback_10 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterColorControlCommandStepColorTemperature_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterColorControlCommandStepColorTemperature_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepColorTemperature_10()
    {
        ChipLogProgress(chipTool, "Color Control - Step up color temperature command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument                 = 1;
        uint16_t stepSizeArgument                = 5U;
        uint16_t transitionTimeArgument          = 50U;
        uint16_t colorTemperatureMinimumArgument = 5U;
        uint16_t colorTemperatureMaximumArgument = 100U;
        uint8_t optionsMaskArgument              = 0;
        uint8_t optionsOverrideArgument          = 0;
        err = cluster.StepColorTemperature(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel(), stepModeArgument,
                                           stepSizeArgument, transitionTimeArgument, colorTemperatureMinimumArgument,
                                           colorTemperatureMaximumArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepColorTemperature_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step up color temperature command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepColorTemperature_10_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step up color temperature command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current color temprature
    using SuccessCallback_11 = void (*)(void * context, uint16_t colorTemperature);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterColorControlCommandReadAttribute_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterColorControlCommandReadAttribute_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_11()
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeColorTemperature(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_11_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_11_SuccessResponse(void * context, uint16_t colorTemperature)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Step down color temperature command
    using SuccessCallback_12 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{
        OnTestSendClusterColorControlCommandStepColorTemperature_12_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{
        OnTestSendClusterColorControlCommandStepColorTemperature_12_FailureResponse, this
    };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandStepColorTemperature_12()
    {
        ChipLogProgress(chipTool, "Color Control - Step down color temperature command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument                 = 3;
        uint16_t stepSizeArgument                = 5U;
        uint16_t transitionTimeArgument          = 50U;
        uint16_t colorTemperatureMinimumArgument = 5U;
        uint16_t colorTemperatureMaximumArgument = 100U;
        uint8_t optionsMaskArgument              = 0;
        uint8_t optionsOverrideArgument          = 0;
        err = cluster.StepColorTemperature(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel(), stepModeArgument,
                                           stepSizeArgument, transitionTimeArgument, colorTemperatureMinimumArgument,
                                           colorTemperatureMaximumArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandStepColorTemperature_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Step down color temperature command: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandStepColorTemperature_12_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Step down color temperature command: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Read current color temprature
    using SuccessCallback_13 = void (*)(void * context, uint16_t colorTemperature);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_13()
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeColorTemperature(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Failure Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse(void * context, uint16_t colorTemperature)
    {
        ChipLogProgress(chipTool, "Color Control - Read current color temprature: Success Response");

        Test_TC_CC_6 * runner = reinterpret_cast<Test_TC_CC_6 *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_CC_7 : public TestCommand
{
public:
    Test_TC_CC_7() : TestCommand("Test_TC_CC_7"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_7: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterOnOffCommandOn_0();
            break;
        case 1:
            err = TestSendClusterOnOffCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterColorControlCommandEnhancedMoveToHue_2();
            break;
        case 3:
            err = TestSendClusterColorControlCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterColorControlCommandReadAttribute_4();
            break;
        case 5:
            err = TestSendClusterColorControlCommandEnhancedMoveHue_5();
            break;
        case 6:
            err = TestSendClusterColorControlCommandEnhancedMoveHue_6();
            break;
        case 7:
            err = TestSendClusterColorControlCommandEnhancedMoveHue_7();
            break;
        case 8:
            err = TestSendClusterColorControlCommandEnhancedMoveHue_8();
            break;
        case 9:
            err = TestSendClusterColorControlCommandEnhancedStepHue_9();
            break;
        case 10:
            err = TestSendClusterColorControlCommandEnhancedStepHue_10();
            break;
        case 11:
            err = TestSendClusterColorControlCommandEnhancedMoveToHueAndSaturation_11();
            break;
        case 12:
            err = TestSendClusterColorControlCommandReadAttribute_12();
            break;
        case 13:
            err = TestSendClusterColorControlCommandReadAttribute_13();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_CC_7: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 14;

    //
    // Tests methods
    //

    // Test Turn on light for color control tests
    using SuccessCallback_0 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{ OnTestSendClusterOnOffCommandOn_0_SuccessResponse, this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{ OnTestSendClusterOnOffCommandOn_0_FailureResponse,
                                                                           this };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandOn_0()
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.On(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandOn_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandOn_0_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "On/Off - Turn on light for color control tests: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check on/off attribute value is true after on command
    using SuccessCallback_1 = void (*)(void * context, uint8_t onOff);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{ OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse,
                                                                      this };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterOnOffCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Sending command...");

        chip::Controller::OnOffCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOnOff(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterOnOffCommandReadAttribute_1_SuccessResponse(void * context, uint8_t onOff)
    {
        ChipLogProgress(chipTool, "On/Off - Check on/off attribute value is true after on command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (onOff != 1)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Move To Hue command
    using SuccessCallback_2 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterColorControlCommandEnhancedMoveToHue_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterColorControlCommandEnhancedMoveToHue_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedMoveToHue_2()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move To Hue command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t enhancedHueArgument    = 1025U;
        uint8_t directionArgument       = 0;
        uint16_t transitionTimeArgument = 1U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedMoveToHue(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel(), enhancedHueArgument,
                                        directionArgument, transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveToHue_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move To Hue command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveToHue_2_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move To Hue command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Remaining time attribute value matched the value sent by the last command
    using SuccessCallback_3 = void (*)(void * context, uint16_t remainingTime);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_3()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Remaining time attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeRemainingTime(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Remaining time attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_3_SuccessResponse(void * context, uint16_t remainingTime)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Remaining time attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (remainingTime != 1U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "1");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check EnhancedCurrentHue attribute value matched the value sent by the last command
    using SuccessCallback_4 = void (*)(void * context, uint16_t enhancedCurrentHue);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterColorControlCommandReadAttribute_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterColorControlCommandReadAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_4()
    {
        ChipLogProgress(chipTool,
                        "Color Control - Check EnhancedCurrentHue attribute value matched the value sent by the last command: "
                        "Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnhancedCurrentHue(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool,
                        "Color Control - Check EnhancedCurrentHue attribute value matched the value sent by the last command: "
                        "Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_4_SuccessResponse(void * context, uint16_t enhancedCurrentHue)
    {
        ChipLogProgress(chipTool,
                        "Color Control - Check EnhancedCurrentHue attribute value matched the value sent by the last command: "
                        "Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Move Hue Down command
    using SuccessCallback_5 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedMoveHue_5()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Down command : Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 3;
        uint16_t rateArgument           = 5U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedMoveHue(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel(), moveModeArgument, rateArgument,
                                      optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Down command : Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_5_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Down command : Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Move Hue Stop command
    using SuccessCallback_6 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedMoveHue_6()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Stop command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 0;
        uint16_t rateArgument           = 0U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedMoveHue(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel(), moveModeArgument, rateArgument,
                                      optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Stop command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_6_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Stop command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Move Hue Up command
    using SuccessCallback_7 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedMoveHue_7()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 1;
        uint16_t rateArgument           = 50U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedMoveHue(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel(), moveModeArgument, rateArgument,
                                      optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Up command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_7_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Up command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Move Hue Stop command
    using SuccessCallback_8 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterColorControlCommandEnhancedMoveHue_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedMoveHue_8()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Stop command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t moveModeArgument        = 0;
        uint16_t rateArgument           = 0U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedMoveHue(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel(), moveModeArgument, rateArgument,
                                      optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Stop command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveHue_8_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Move Hue Stop command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Step Hue Up command
    using SuccessCallback_9 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterColorControlCommandEnhancedStepHue_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterColorControlCommandEnhancedStepHue_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedStepHue_9()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Step Hue Up command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument        = 0;
        uint16_t stepSizeArgument       = 50U;
        uint16_t transitionTimeArgument = 1U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedStepHue(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel(), stepModeArgument,
                                      stepSizeArgument, transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedStepHue_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Step Hue Up command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedStepHue_9_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Step Hue Up command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced Step Hue Down command
    using SuccessCallback_10 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterColorControlCommandEnhancedStepHue_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterColorControlCommandEnhancedStepHue_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedStepHue_10()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Step Hue Down command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t stepModeArgument        = 1;
        uint16_t stepSizeArgument       = 75U;
        uint16_t transitionTimeArgument = 1U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedStepHue(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel(), stepModeArgument,
                                      stepSizeArgument, transitionTimeArgument, optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedStepHue_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Step Hue Down command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedStepHue_10_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced Step Hue Down command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Enhanced move to hue and saturation command
    using SuccessCallback_11 = void (*)(void * context);
    chip::Callback::Callback<SuccessCallback_11> mOnSuccessCallback_11{
        OnTestSendClusterColorControlCommandEnhancedMoveToHueAndSaturation_11_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_11{
        OnTestSendClusterColorControlCommandEnhancedMoveToHueAndSaturation_11_FailureResponse, this
    };
    bool mIsFailureExpected_11 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandEnhancedMoveToHueAndSaturation_11()
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced move to hue and saturation command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint16_t enhancedHueArgument    = 1200U;
        uint8_t saturationArgument      = 90;
        uint16_t transitionTimeArgument = 10U;
        uint8_t optionsMaskArgument     = 0;
        uint8_t optionsOverrideArgument = 0;
        err = cluster.EnhancedMoveToHueAndSaturation(mOnSuccessCallback_11.Cancel(), mOnFailureCallback_11.Cancel(),
                                                     enhancedHueArgument, saturationArgument, transitionTimeArgument,
                                                     optionsMaskArgument, optionsOverrideArgument);

        return err;
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveToHueAndSaturation_11_FailureResponse(void * context,
                                                                                                      uint8_t status)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced move to hue and saturation command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_11 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandEnhancedMoveToHueAndSaturation_11_SuccessResponse(void * context)
    {
        ChipLogProgress(chipTool, "Color Control - Enhanced move to hue and saturation command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_11 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check EnhancedCurrentHue attribute value matched the value sent by the last command
    using SuccessCallback_12 = void (*)(void * context, uint16_t enhancedCurrentHue);
    chip::Callback::Callback<SuccessCallback_12> mOnSuccessCallback_12{
        OnTestSendClusterColorControlCommandReadAttribute_12_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_12{
        OnTestSendClusterColorControlCommandReadAttribute_12_FailureResponse, this
    };
    bool mIsFailureExpected_12 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_12()
    {
        ChipLogProgress(chipTool,
                        "Color Control - Check EnhancedCurrentHue attribute value matched the value sent by the last command: "
                        "Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEnhancedCurrentHue(mOnSuccessCallback_12.Cancel(), mOnFailureCallback_12.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_12_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool,
                        "Color Control - Check EnhancedCurrentHue attribute value matched the value sent by the last command: "
                        "Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_12 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_12_SuccessResponse(void * context, uint16_t enhancedCurrentHue)
    {
        ChipLogProgress(chipTool,
                        "Color Control - Check EnhancedCurrentHue attribute value matched the value sent by the last command: "
                        "Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_12 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test Check Saturation attribute value matched the value sent by the last command
    using SuccessCallback_13 = void (*)(void * context, uint8_t currentSaturation);
    chip::Callback::Callback<SuccessCallback_13> mOnSuccessCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_13{
        OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse, this
    };
    bool mIsFailureExpected_13 = 0;

    CHIP_ERROR TestSendClusterColorControlCommandReadAttribute_13()
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Sending command...");

        chip::Controller::ColorControlCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeCurrentSaturation(mOnSuccessCallback_13.Cancel(), mOnFailureCallback_13.Cancel());

        return err;
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Failure Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_13 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterColorControlCommandReadAttribute_13_SuccessResponse(void * context, uint8_t currentSaturation)
    {
        ChipLogProgress(
            chipTool,
            "Color Control - Check Saturation attribute value matched the value sent by the last command: Success Response");

        Test_TC_CC_7 * runner = reinterpret_cast<Test_TC_CC_7 *>(context);

        if (runner->mIsFailureExpected_13 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_WNCV_1_1 : public TestCommand
{
public:
    Test_TC_WNCV_1_1() : TestCommand("Test_TC_WNCV_1_1"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_WNCV_1_1: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterWindowCoveringCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterWindowCoveringCommandReadAttribute_1();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_WNCV_1_1: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 2;

    //
    // Tests methods
    //

    // Test read the global attribute: ClusterRevision
    using SuccessCallback_0 = void (*)(void * context, uint16_t clusterRevision);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterWindowCoveringCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterWindowCoveringCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Window Covering - read the global attribute: ClusterRevision: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeClusterRevision(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - read the global attribute: ClusterRevision: Failure Response");

        Test_TC_WNCV_1_1 * runner = reinterpret_cast<Test_TC_WNCV_1_1 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_0_SuccessResponse(void * context, uint16_t clusterRevision)
    {
        ChipLogProgress(chipTool, "Window Covering - read the global attribute: ClusterRevision: Success Response");

        Test_TC_WNCV_1_1 * runner = reinterpret_cast<Test_TC_WNCV_1_1 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (clusterRevision != 3U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back global attribute: ClusterRevision
    using SuccessCallback_1 = void (*)(void * context, uint16_t clusterRevision);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterWindowCoveringCommandReadAttribute_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterWindowCoveringCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "Window Covering - reads back global attribute: ClusterRevision: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeClusterRevision(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back global attribute: ClusterRevision: Failure Response");

        Test_TC_WNCV_1_1 * runner = reinterpret_cast<Test_TC_WNCV_1_1 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_1_SuccessResponse(void * context, uint16_t clusterRevision)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back global attribute: ClusterRevision: Success Response");

        Test_TC_WNCV_1_1 * runner = reinterpret_cast<Test_TC_WNCV_1_1 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (clusterRevision != 3U)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

class Test_TC_WNCV_2_1 : public TestCommand
{
public:
    Test_TC_WNCV_2_1() : TestCommand("Test_TC_WNCV_2_1"), mTestIndex(0) {}

    /////////// TestCommand Interface /////////
    void NextTest() override
    {
        CHIP_ERROR err = CHIP_NO_ERROR;

        if (mTestCount == mTestIndex)
        {
            ChipLogProgress(chipTool, "Test_TC_WNCV_2_1: Test complete");
            SetCommandExitStatus(CHIP_NO_ERROR);
        }

        // Ensure we increment mTestIndex before we start running the relevant
        // command.  That way if we lose the timeslice after we send the message
        // but before our function call returns, we won't end up with an
        // incorrect mTestIndex value observed when we get the response.
        switch (mTestIndex++)
        {
        case 0:
            err = TestSendClusterWindowCoveringCommandReadAttribute_0();
            break;
        case 1:
            err = TestSendClusterWindowCoveringCommandReadAttribute_1();
            break;
        case 2:
            err = TestSendClusterWindowCoveringCommandReadAttribute_2();
            break;
        case 3:
            err = TestSendClusterWindowCoveringCommandReadAttribute_3();
            break;
        case 4:
            err = TestSendClusterWindowCoveringCommandReadAttribute_4();
            break;
        case 5:
            err = TestSendClusterWindowCoveringCommandReadAttribute_5();
            break;
        case 6:
            err = TestSendClusterWindowCoveringCommandReadAttribute_6();
            break;
        case 7:
            err = TestSendClusterWindowCoveringCommandReadAttribute_7();
            break;
        case 8:
            err = TestSendClusterWindowCoveringCommandReadAttribute_8();
            break;
        case 9:
            err = TestSendClusterWindowCoveringCommandWriteAttribute_9();
            break;
        case 10:
            err = TestSendClusterWindowCoveringCommandReadAttribute_10();
            break;
        }

        if (CHIP_NO_ERROR != err)
        {
            ChipLogProgress(chipTool, "Test_TC_WNCV_2_1: %s", chip::ErrorStr(err));
            SetCommandExitStatus(err);
        }
    }

private:
    std::atomic_uint16_t mTestIndex;
    const uint16_t mTestCount = 11;

    //
    // Tests methods
    //

    // Test read the RO mandatory attribute default: Type
    using SuccessCallback_0 = void (*)(void * context, uint8_t type);
    chip::Callback::Callback<SuccessCallback_0> mOnSuccessCallback_0{
        OnTestSendClusterWindowCoveringCommandReadAttribute_0_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_0{
        OnTestSendClusterWindowCoveringCommandReadAttribute_0_FailureResponse, this
    };
    bool mIsFailureExpected_0 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_0()
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: Type: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeType(mOnSuccessCallback_0.Cancel(), mOnFailureCallback_0.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_0_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: Type: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_0 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_0_SuccessResponse(void * context, uint8_t type)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: Type: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_0 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (type != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back the RO mandatory attribute: Type
    using SuccessCallback_1 = void (*)(void * context, uint8_t type);
    chip::Callback::Callback<SuccessCallback_1> mOnSuccessCallback_1{
        OnTestSendClusterWindowCoveringCommandReadAttribute_1_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_1{
        OnTestSendClusterWindowCoveringCommandReadAttribute_1_FailureResponse, this
    };
    bool mIsFailureExpected_1 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_1()
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: Type: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeType(mOnSuccessCallback_1.Cancel(), mOnFailureCallback_1.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_1_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: Type: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_1 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_1_SuccessResponse(void * context, uint8_t type)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: Type: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_1 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (type != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read the RO mandatory attribute default: ConfigStatus
    using SuccessCallback_2 = void (*)(void * context, uint8_t configStatus);
    chip::Callback::Callback<SuccessCallback_2> mOnSuccessCallback_2{
        OnTestSendClusterWindowCoveringCommandReadAttribute_2_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_2{
        OnTestSendClusterWindowCoveringCommandReadAttribute_2_FailureResponse, this
    };
    bool mIsFailureExpected_2 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_2()
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: ConfigStatus: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeConfigStatus(mOnSuccessCallback_2.Cancel(), mOnFailureCallback_2.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_2_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: ConfigStatus: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_2 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_2_SuccessResponse(void * context, uint8_t configStatus)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: ConfigStatus: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_2 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (configStatus != 3)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back the RO mandatory attribute: ConfigStatus
    using SuccessCallback_3 = void (*)(void * context, uint8_t configStatus);
    chip::Callback::Callback<SuccessCallback_3> mOnSuccessCallback_3{
        OnTestSendClusterWindowCoveringCommandReadAttribute_3_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_3{
        OnTestSendClusterWindowCoveringCommandReadAttribute_3_FailureResponse, this
    };
    bool mIsFailureExpected_3 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_3()
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: ConfigStatus: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeConfigStatus(mOnSuccessCallback_3.Cancel(), mOnFailureCallback_3.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_3_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: ConfigStatus: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_3 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_3_SuccessResponse(void * context, uint8_t configStatus)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: ConfigStatus: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_3 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (configStatus != 3)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "3");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read the RO mandatory attribute default: OperationalStatus
    using SuccessCallback_4 = void (*)(void * context, uint8_t operationalStatus);
    chip::Callback::Callback<SuccessCallback_4> mOnSuccessCallback_4{
        OnTestSendClusterWindowCoveringCommandReadAttribute_4_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_4{
        OnTestSendClusterWindowCoveringCommandReadAttribute_4_FailureResponse, this
    };
    bool mIsFailureExpected_4 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_4()
    {
        ChipLogProgress(chipTool,
                        "Window Covering - read the RO mandatory attribute default: OperationalStatus: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOperationalStatus(mOnSuccessCallback_4.Cancel(), mOnFailureCallback_4.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_4_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: OperationalStatus: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_4 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_4_SuccessResponse(void * context, uint8_t operationalStatus)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: OperationalStatus: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_4 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (operationalStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back the RO mandatory attribute: OperationalStatus
    using SuccessCallback_5 = void (*)(void * context, uint8_t operationalStatus);
    chip::Callback::Callback<SuccessCallback_5> mOnSuccessCallback_5{
        OnTestSendClusterWindowCoveringCommandReadAttribute_5_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_5{
        OnTestSendClusterWindowCoveringCommandReadAttribute_5_FailureResponse, this
    };
    bool mIsFailureExpected_5 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_5()
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: OperationalStatus: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeOperationalStatus(mOnSuccessCallback_5.Cancel(), mOnFailureCallback_5.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_5_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: OperationalStatus: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_5 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_5_SuccessResponse(void * context, uint8_t operationalStatus)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: OperationalStatus: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_5 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (operationalStatus != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read the RO mandatory attribute default: EndProductType
    using SuccessCallback_6 = void (*)(void * context, uint8_t endProductType);
    chip::Callback::Callback<SuccessCallback_6> mOnSuccessCallback_6{
        OnTestSendClusterWindowCoveringCommandReadAttribute_6_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_6{
        OnTestSendClusterWindowCoveringCommandReadAttribute_6_FailureResponse, this
    };
    bool mIsFailureExpected_6 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_6()
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: EndProductType: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEndProductType(mOnSuccessCallback_6.Cancel(), mOnFailureCallback_6.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_6_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: EndProductType: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_6 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_6_SuccessResponse(void * context, uint8_t endProductType)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RO mandatory attribute default: EndProductType: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_6 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (endProductType != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back the RO mandatory attribute: EndProductType
    using SuccessCallback_7 = void (*)(void * context, uint8_t endProductType);
    chip::Callback::Callback<SuccessCallback_7> mOnSuccessCallback_7{
        OnTestSendClusterWindowCoveringCommandReadAttribute_7_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_7{
        OnTestSendClusterWindowCoveringCommandReadAttribute_7_FailureResponse, this
    };
    bool mIsFailureExpected_7 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_7()
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: EndProductType: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeEndProductType(mOnSuccessCallback_7.Cancel(), mOnFailureCallback_7.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_7_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: EndProductType: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_7 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_7_SuccessResponse(void * context, uint8_t endProductType)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RO mandatory attribute: EndProductType: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_7 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (endProductType != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test read the RW mandatory attribute default: Mode
    using SuccessCallback_8 = void (*)(void * context, uint8_t mode);
    chip::Callback::Callback<SuccessCallback_8> mOnSuccessCallback_8{
        OnTestSendClusterWindowCoveringCommandReadAttribute_8_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_8{
        OnTestSendClusterWindowCoveringCommandReadAttribute_8_FailureResponse, this
    };
    bool mIsFailureExpected_8 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_8()
    {
        ChipLogProgress(chipTool, "Window Covering - read the RW mandatory attribute default: Mode: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeMode(mOnSuccessCallback_8.Cancel(), mOnFailureCallback_8.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_8_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RW mandatory attribute default: Mode: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_8 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_8_SuccessResponse(void * context, uint8_t mode)
    {
        ChipLogProgress(chipTool, "Window Covering - read the RW mandatory attribute default: Mode: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_8 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mode != 0)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "0");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test write a value into the RW mandatory attribute:: Mode
    using SuccessCallback_9 = void (*)(void * context, uint8_t mode);
    chip::Callback::Callback<SuccessCallback_9> mOnSuccessCallback_9{
        OnTestSendClusterWindowCoveringCommandWriteAttribute_9_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_9{
        OnTestSendClusterWindowCoveringCommandWriteAttribute_9_FailureResponse, this
    };
    bool mIsFailureExpected_9 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandWriteAttribute_9()
    {
        ChipLogProgress(chipTool, "Window Covering - write a value into the RW mandatory attribute:: Mode: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        uint8_t modeArgument = 7;
        err = cluster.WriteAttributeMode(mOnSuccessCallback_9.Cancel(), mOnFailureCallback_9.Cancel(), modeArgument);

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandWriteAttribute_9_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - write a value into the RW mandatory attribute:: Mode: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_9 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandWriteAttribute_9_SuccessResponse(void * context, uint8_t mode)
    {
        ChipLogProgress(chipTool, "Window Covering - write a value into the RW mandatory attribute:: Mode: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_9 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    // Test reads back the RW mandatory attribute: Mode
    using SuccessCallback_10 = void (*)(void * context, uint8_t mode);
    chip::Callback::Callback<SuccessCallback_10> mOnSuccessCallback_10{
        OnTestSendClusterWindowCoveringCommandReadAttribute_10_SuccessResponse, this
    };
    chip::Callback::Callback<DefaultFailureCallback> mOnFailureCallback_10{
        OnTestSendClusterWindowCoveringCommandReadAttribute_10_FailureResponse, this
    };
    bool mIsFailureExpected_10 = 0;

    CHIP_ERROR TestSendClusterWindowCoveringCommandReadAttribute_10()
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RW mandatory attribute: Mode: Sending command...");

        chip::Controller::WindowCoveringCluster cluster;
        cluster.Associate(mDevice, 1);

        CHIP_ERROR err = CHIP_NO_ERROR;

        err = cluster.ReadAttributeMode(mOnSuccessCallback_10.Cancel(), mOnFailureCallback_10.Cancel());

        return err;
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_10_FailureResponse(void * context, uint8_t status)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RW mandatory attribute: Mode: Failure Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_10 == false)
        {
            ChipLogError(chipTool, "Error: The test was expecting a success callback. Got failure callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }

    static void OnTestSendClusterWindowCoveringCommandReadAttribute_10_SuccessResponse(void * context, uint8_t mode)
    {
        ChipLogProgress(chipTool, "Window Covering - reads back the RW mandatory attribute: Mode: Success Response");

        Test_TC_WNCV_2_1 * runner = reinterpret_cast<Test_TC_WNCV_2_1 *>(context);

        if (runner->mIsFailureExpected_10 == true)
        {
            ChipLogError(chipTool, "Error: The test was expecting a failure callback. Got success callback");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        if (mode != 7)
        {
            ChipLogError(chipTool, "Error: Value mismatch. Expected: '%s'", "7");
            runner->SetCommandExitStatus(CHIP_ERROR_INTERNAL);
            return;
        }

        runner->NextTest();
    }
};

void registerCommandsTests(Commands & commands)
{
    const char * clusterName = "Tests";

    commands_list clusterCommands = {
        make_unique<TV_TargetNavigatorCluster>(),
        make_unique<TV_AudioOutputCluster>(),
        make_unique<TV_ApplicationLauncherCluster>(),
        make_unique<TV_KeypadInputCluster>(),
        make_unique<TV_AccountLoginCluster>(),
        make_unique<TV_ApplicationBasicCluster>(),
        make_unique<TV_MediaPlaybackCluster>(),
        make_unique<TV_TvChannelCluster>(),
        make_unique<TV_LowPowerCluster>(),
        make_unique<TV_MediaInputCluster>(),
        make_unique<TestCluster>(),
        make_unique<Test_TC_OO_1_1>(),
        make_unique<Test_TC_OO_2_1>(),
        make_unique<Test_TC_OO_2_2>(),
        make_unique<Test_TC_DM_1_1>(),
        make_unique<Test_TC_DM_3_1>(),
        make_unique<Test_TC_CC_3_4>(),
        make_unique<Test_TC_CC_5>(),
        make_unique<Test_TC_CC_6>(),
        make_unique<Test_TC_CC_7>(),
        make_unique<Test_TC_WNCV_1_1>(),
        make_unique<Test_TC_WNCV_2_1>(),
    };

    commands.Register(clusterName, clusterCommands);
}
